���� JFIF    �� �        "" $(4,$&1'-=-157:::#+?D?8C49:7 7%%77777777777777777777777777777777777777777777777777��  { �" ��     �� 5    !1AQa"q�2��BR��#b�������  ��  ��   ? ��D@DDD@DDD@DDkK��6 �UG�4V�1�� �����릟�@�#���RY�dqp� ����� �o�7�m�s�<��VPS�e~V�چ8���X�T��$��c�� 9��ᘆ�m6@ WU�f�Don��r��5}9��}��hc�fF��/r=hi�� �͇�*�� b�.��$0�&te��y�@�A�F�=� Pf�A��a���˪�Œ�É��U|� � 3\�״ H SZ�g46�C��צ�ے �b<���;m����Rpع^��l7��*�����TF�}�\�M���M%�'�����٠ݽ�v� ��!-�����?�N!La��A+[`#���M����'�~oR�?��v^)��=��h����A��X�.���˃����^Ə��ܯsO"B�c>; �e�4��5�k��/CB��.  �J?��;�҈�������������������~�<�VZ�ꭼ2/)Í”jC���ע�V�G�!���!�F������\�� Kj�R�oc�h���:Þ I��1"2�q×°8��Р@ז���_C0�ր��A��lQ��@纼�!7��F�� �]�sZ B�62r�v�z~�K�7�c��5�.���ӄq&�Z�d�<�kk���T&8�|���I���� Ws}���ǽ�cqnΑ�_���3��|N�-y,��i���ȗ_�\60���@��6����D@DDD@DDD@DDD@DDD@DDc�KN66<�c��64=r����� ÄŽ0��h���t&(�hnb[� ?��^��\��â|�,�/h�\��R��5�? �0�!צ܉-����G����٬��Q�zA���1�����V��� �:R���`�$��ik��H����D4�����#dk����� h�}����7���w%�������*o8wG�LycuT�.���ܯ7��I��u^���)��/c�,s�Nq�ۺ�;�ך�YH2���.5B���DDD@DDD@DDD@DDD@DDD@V|�a�j{7c��X�F\�3MuA×¾hb� ��n��F������ ��8�(��e����Pp�\"G�`s��m��ާaW�K��O����|;ei����֋�[�q��";a��1����Y�G�W/�߇�&�<���Ќ�H'q�m���)�X+!���=�m�ۚ丷~6a^X�)���,�>#&6G���Y��{����"" """ """ """ """ ""��at\/�a�8 �yp%�lhl�n����)���i�t��B�������������?��modskinlienminh.com - WSOX ENC home/thedmlab/public_html/wp-content/plugins/wp-retina-3x/wr2x_admin.php000064400000060567146731432730022406 0ustar00

"; _e( "JetPack's Photon module breaks features built in WP Retina 3x (as Photos moves the files away). A common and better alternative to Photon is to use MaxCDN (very popular), CloudFlare or Fastly.", 'wp-retina-3x' ); echo "

"; } } static function activate() { global $wp_rewrite; $wp_rewrite->flush_rules(); } static function deactivate() { remove_filter( 'generate_rewrite_rules', array( 'Meow_wr3x_Admin', 'generate_rewrite_rules' ) ); global $wp_rewrite; $wp_rewrite->flush_rules(); } static function generate_rewrite_rules( $wp_rewrite, $flush = false ) { global $wp_rewrite; $method = get_option( "wr3x_method" ); if ( $method == "Retina-Images" ) { // MODIFICATION: docwhat // get_home_url() -> trailingslashit(site_url()) // REFERENCE: http://wordpress.org/support/topic/plugin-wp-retina-3x-htaccess-generated-with-incorrect-rewriterule // MODIFICATION BY h4ir9 // .*\.(jpg|jpeg|gif|png|bmp) -> (.+.(?:jpe?g|gif|png)) // REFERENCE: http://wordpress.org/support/topic/great-but-needs-a-little-update $handlerurl = str_replace( trailingslashit( site_url()), '', plugins_url( 'wr3x_image.php', __FILE__ ) ); add_rewrite_rule( '(.+.(?:jpe?g|gif|png))', $handlerurl, 'top' ); } if ( $flush == true ) { $wp_rewrite->flush_rules(); } } function common_url( $file ) { return trailingslashit( plugin_dir_url( __FILE__ ) ) . 'common/' . $file; } function app_menu() { // SUBMENU > Settings add_submenu_page( 'meowapps-main-menu', 'Retina', 'Retina', 'manage_options', 'wr3x_settings-menu', array( $this, 'admin_settings' ) ); // SUBMENU > Settings > Basic Settings add_settings_section( 'wr3x_settings', null, null, 'wr3x_settings-menu' ); add_settings_field( 'wr3x_ignore_sizes', __( "Disabled Sizes", 'wp-retina-3x' ), array( $this, 'admin_ignore_sizes_callback' ), 'wr3x_settings-menu', 'wr3x_settings' ); add_settings_field( 'wr3x_method', __( "Method", 'wp-retina-3x' ), array( $this, 'admin_method_callback' ), 'wr3x_settings-menu', 'wr3x_settings' ); add_settings_field( 'wr3x_full_size', __( "Full Size Retina", 'wp-retina-3x' ) . "
(Pro)", array( $this, 'admin_full_size_callback' ), 'wr3x_settings-menu', 'wr3x_settings' ); // add_settings_field( 'wr3x_method', __( "Method", 'wp-retina-3x' ), // array( $this, 'admin_method_callback' ), // 'wr3x_settings-menu', 'wr3x_settings' ); add_settings_field( 'wr3x_quality', __( "Retina Quality", 'wp-retina-3x' ), array( $this, 'admin_quality_callback' ), 'wr3x_settings-menu', 'wr3x_settings' ); //// Default Disabled Sizes $defaults = array (); $sizes = $this->core->get_image_sizes(); $large_w = 1600; $large_h = 1200; foreach ( $sizes as $name => $details ) { $w = isset($details['width']) ? $details['width'] : 0; $h = isset($details['height']) ? $details['height'] : 0; if ( $w >= $large_w || $h >= $large_h ) $defaults[$name] = 1; } register_setting( 'wr3x_settings', 'wr3x_ignore_sizes', array ( 'default' => $defaults ) ); register_setting( 'wr3x_settings', 'wr3x_full_size' ); register_setting( 'wr3x_settings', 'wr3x_method' ); register_setting( 'wr3x_settings', 'wr3x_quality' ); // SUBMENU > Settings > Advanced Settings add_settings_section( 'wr3x_advanced_settings', null, null, 'wr3x_advanced_settings-menu' ); add_settings_field( 'wr3x_auto_generate', __( "Auto Generate", 'wp-retina-3x' ), array( $this, 'admin_auto_generate_callback' ), 'wr3x_advanced_settings-menu', 'wr3x_advanced_settings' ); add_settings_field( 'wr3x_regenerate_thumbnails', __( "Regenerate Thumbnails", 'wp-retina-3x' ), array( $this, 'admin_regenerate_thumbnails_callback' ), 'wr3x_advanced_settings-menu', 'wr3x_advanced_settings' ); add_settings_field( 'wr3x_disable_medium_large', __( "Disable Medium Large", 'wp-retina-3x' ), array( $this, 'admin_disable_medium_large_callback' ), 'wr3x_advanced_settings-menu', 'wr3x_advanced_settings' ); add_settings_field( 'wr3x_over_http_check', __( "Over HTTP Check", 'wp-retina-3x' ) . "
(Pro)", array( $this, 'admin_over_http_check_callback' ), 'wr3x_advanced_settings-menu', 'wr3x_advanced_settings' ); add_settings_field( 'wr3x_debug', __( "Debug", 'wp-retina-3x' ), array( $this, 'admin_debug_callback' ), 'wr3x_advanced_settings-menu', 'wr3x_advanced_settings' ); add_settings_field( 'wr3x_disable_responsive', __( "Disable Responsive", 'wp-retina-3x' ), array( $this, 'admin_disable_responsive_callback' ), 'wr3x_advanced_settings-menu', 'wr3x_advanced_settings' ); add_settings_field( 'wr3x_cdn_domain', __( "Custom CDN Domain", 'wp-retina-3x' ) . "
(Pro)", array( $this, 'admin_cdn_domain_callback' ), 'wr3x_advanced_settings-menu', 'wr3x_advanced_settings' ); add_settings_field( 'wr3x_big_image_size_threshold', __( "Big Image Size Threshold", 'wp-retina-3x' ), array( $this, 'admin_big_image_size_threshold' ), 'wr3x_advanced_settings-menu', 'wr3x_advanced_settings' ); register_setting( 'wr3x_advanced_settings', 'wr3x_auto_generate' ); register_setting( 'wr3x_advanced_settings', 'wr3x_regenerate_thumbnails' ); register_setting( 'wr3x_advanced_settings', 'wr3x_disable_responsive' ); register_setting( 'wr3x_advanced_settings', 'wr3x_disable_medium_large' ); register_setting( 'wr3x_advanced_settings', 'wr3x_cdn_domain' ); register_setting( 'wr3x_advanced_settings', 'wr3x_big_image_size_threshold' ); register_setting( 'wr3x_advanced_settings', 'wr3x_over_http_check' ); register_setting( 'wr3x_advanced_settings', 'wr3x_debug' ); // SUBMENU > Settings > PictureFill add_settings_section( 'wr3x_picturefill_settings', null, null, 'wr3x_picturefill_settings-menu' ); add_settings_field( 'wr3x_picturefill_keep_src', "Keep IMG SRC", array( $this, 'admin_picturefill_keep_src_callback' ), 'wr3x_picturefill_settings-menu', 'wr3x_picturefill_settings' ); add_settings_field( 'wr3x_picturefill_lazysizes', "Lazy Retina
(Pro)", array( $this, 'admin_picturefill_lazysizes_callback' ), 'wr3x_picturefill_settings-menu', 'wr3x_picturefill_settings' ); add_settings_field( 'wr3x_picturefill_css_background', "CSS Background
(Pro)", array( $this, 'admin_picturefill_css_background_callback' ), 'wr3x_picturefill_settings-menu', 'wr3x_picturefill_settings' ); add_settings_field( 'wr3x_picturefill_noscript', "Polyfill Script", array( $this, 'admin_picturefill_noscript_callback' ), 'wr3x_picturefill_settings-menu', 'wr3x_picturefill_settings' ); register_setting( 'wr3x_picturefill_settings', 'wr3x_picturefill_keep_src' ); register_setting( 'wr3x_picturefill_settings', 'wr3x_picturefill_lazysizes' ); register_setting( 'wr3x_picturefill_settings', 'wr3x_picturefill_css_background' ); register_setting( 'wr3x_picturefill_settings', 'wr3x_picturefill_noscript' ); // SUBMENU > Settings > Admin UI add_settings_section( 'wr3x_ui_settings', null, null, 'wr3x_ui_settings-menu' ); add_settings_field( 'wr3x_hide_retina_column', __( "Retina Column", 'wp-retina-3x' ), array( $this, 'admin_hide_retina_column_callback' ), 'wr3x_ui_settings-menu', 'wr3x_ui_settings' ); add_settings_field( 'wr3x_hide_retina_dashboard', __( "Retina Dashboard", 'wp-retina-3x' ), array( $this, 'admin_hide_retina_dashboard_callback' ), 'wr3x_ui_settings-menu', 'wr3x_ui_settings' ); add_settings_field( 'wr3x_hide_pro', __( "Pro Information", 'wp-retina-3x' ), array( $this, 'admin_hide_pro_callback' ), 'wr3x_ui_settings-menu', 'wr3x_ui_settings' ); register_setting( 'wr3x_ui_settings', 'wr3x_hide_retina_column' ); register_setting( 'wr3x_ui_settings', 'wr3x_hide_retina_dashboard' ); register_setting( 'wr3x_ui_settings', 'wr3x_hide_pro' ); } function admin_settings() { $method = get_option( 'wr3x_method', 'Picturefill' ); $quality = get_option( 'wr3x_quality', 90 ); if ( $quality > 100 || $quality < 0 ) update_option( 'wr3x_quality', 90, false ); ?>
display_title( "WP Retina 3x" ); ?>
" . __( "Current method:", 'wp-retina-3x' ) . " " . __( "None", 'wp-retina-3x' ) . "."; if ( $method == 'HTML Rewrite' ) echo "

" . __( "Current method:", 'wp-retina-3x' ) . " " . __( "HTML Rewrite", 'wp-retina-3x' ) . "."; if ( $method == 'retina.js' ) echo "

" . __( "Current method:", 'wp-retina-3x' ) . " " . __( "Retina.js", 'wp-retina-3x' ) . "."; if ( $method == 'Picturefill' ) echo "

" . __( "Current method:", 'wp-retina-3x' ) . " " . __( "PictureFill", 'wp-retina-3x' ) . "."; if ( $method == 'Responsive' ) echo "

" . __( "Current method:", 'wp-retina-3x' ) . " " . __( "Responsive Images", 'wp-retina-3x' ) . "."; if ( $method == 'Retina-Images' ) { echo "

" . __( "Current method:", 'wp-retina-3x' ) . " " . __( "HTML Rewrite", 'wp-retina-3x' ) . "."; if ( defined( 'MULTISITE' ) && MULTISITE == true ) { if ( get_site_option( 'ms_files_rewriting' ) ) { // MODIFICATION: Craig Foster // 'ms_files_rewriting' support echo " " . __( "By the way, you are using a WordPress Multi-Site installation! You must edit your .htaccess manually and add 'RewriteRule ^files/(.+) wp-content/plugins/wp-retina-3x/wr3x_image.php?ms=true&file=$1 [L]' as the first RewriteRule if you want the server-side to work.", 'wp-retina-3x' ) . ""; } else echo " " . __( "By the way, you are using a WordPress Multi-Site installation! You must edit your .htaccess manually and add 'RewriteRule ^(wp-content/.+\.(png|gif|jpg|jpeg|bmp|PNG|GIF|JPG|JPEG|BMP)) wp-content/plugins/wp-retina-3x/wr3x_image.php?ms=true&file=$1 [L]' as the first RewriteRule if you want the server-side to work.", 'wp-retina-3x' ) . ""; } echo "

"; if ( !get_option('permalink_structure') ) echo "

" . __( "The permalinks are not enabled. They need to be enabled in order to use the server-side method.", 'wp-retina-3x' ) . ""; } ?>

How to use

tutorial.', 'wp-retina-3x' ) ?>

Basic Settings

Advanced Settings

display_serialkey_box( "https://meowapps.com/plugin/wp-retina-3x/" ); ?>

PictureFill

Admin UI

core->get_image_sizes(); $sizes = array(); $html = ""; foreach ( $wpsizes as $name => $attr ) { $html .= '' . sprintf( " (Normal: %dx%d, Retina: %dx%d)", MeowApps_Admin::size_shortname( $name ), $name, $attr['width'], $attr['height'], $attr['width'] * 2, $attr['height'] * 2 ) . '
'; } $html .= '
' . __( 'The selected sizes will not have their retina equivalent generated. It is recommended to disable the sizes for which Normal superior to 1200.', 'wp-retina-3x' ) . ''; echo $html; } function admin_auto_generate_callback( $args ) { $value = get_option( 'wr3x_auto_generate', null ); $html = ''; $html .= '
Generate the Retina thumbnails on new upload and thumbnails creation. The Disabled Sizes will be skipped.'; echo $html; } function admin_regenerate_thumbnails_callback( $args ) { $value = get_option( 'wr3x_regenerate_thumbnails', false ); $html = ''; $html .= '
On each Generate action, all standard thumbnails will be regenerated (exactly the same function as Regenerate Thumbnail), and only then the Retina thumbnails will be created (depending on the Auto Generate option).'; echo $html; } function admin_disable_responsive_callback( $args ) { $value = get_option( 'wr3x_disable_responsive', null ); $html = ''; $html .= '
Get back control over your HTML if you need.'; echo $html; } function admin_big_image_size_threshold( $args ) { $value = get_option( 'wr3x_big_image_size_threshold', null ); $html = ''; $html .= '
By default, WordPress limits the size of the image to 2560px (with or height) maximum.'; echo $html; } function admin_disable_medium_large_callback( $args ) { $value = get_option( 'wr3x_disable_medium_large', null ); $html = ''; $html .= '
You probably don\'t need this.'; echo $html; } function admin_method_callback( $args ) { $value = get_option( 'wr3x_method', 'none' ); $html = '
' . __( 'In all cases (including "None"), Retina support will be added to the Responsive Images. Check the Retina Methods page if you want to know more about those methods.', 'wp-retina-3x' ) . '
'; echo $html; } function admin_full_size_callback( $args ) { $value = get_option( 'wr3x_full_size', null ); $html = 'is_registered(), false, false ) . ' type="checkbox" id="wr3x_full_size" name="wr3x_full_size" value="1" ' . checked( 1, get_option( 'wr3x_full_size' ), false ) . '/>'; $html .= '
Checks for retina for full-size will be enabled and upload features made available in the Retina Dashboard.'; echo $html; } function admin_quality_callback( $args ) { $value = get_option( 'wr3x_quality', 90 ); $html = ''; $html .= __( '
Sets image compression quality on a 1-100% scale as an integer (1-100). Default is 90. Only for JPG.', 'wp-retina-3x' ); echo $html; } function admin_debug_callback( $args ) { $value = get_option( 'wr3x_debug', null ); $html = ''; $html .= __( '
Displays retina and creates a log file in the plugin folder.', 'wp-retina-3x' ); echo $html; } function admin_cdn_domain_callback( $args ) { $value = get_option( 'wr3x_cdn_domain', null ); $html = 'is_registered(), false, false ) . ' type="text" id="wr3x_cdn_domain" name="wr3x_cdn_domain" value="' . $value . '" />'; $html .= __( '
If not empty, your site domain will be replaced with this CDN domain (PictureFill and HTML Rewrite only).', 'wp-retina-3x' ); echo $html; } function admin_over_http_check_callback( $args ) { $value = get_option( 'wr3x_over_http_check', null ); $html = 'is_registered(), false, false ) . ' type="checkbox" id="wr3x_over_http_check" name="wr3x_over_http_check" value="1" ' . checked( 1, get_option( 'wr3x_over_http_check' ), false ) . '/>'; $html .= __( '
Normally, the plugin checks if the Retina files exists through your filesystem. With this option, it will check using HTTP requests, that will enable Retina on exotic WordPress installs and also for images hosted on different servers.', 'wp-retina-3x' ); echo $html; } function admin_picturefill_keep_src_callback( $args ) { $value = get_option( 'wr3x_picturefill_keep_src', null ); $html = ''; $html .= __( '
With PictureFill, src tags are replaced by src-set tags, but Google might fail to reference those images. This option will keep the SRC for SEO purpose, but that will force the download of two images (standard, then retina) by the browsers. Please use the Lazy Retina option below as it avoid this to happen (as well as making it loading lazily).', 'wp-retina-3x' ); echo $html; } function admin_picturefill_lazysizes_callback( $args ) { $value = get_option( 'wr3x_picturefill_lazysizes', null ); $html = 'is_registered(), false, false ) . ' type="checkbox" id="wr3x_picturefill_lazysizes" name="wr3x_picturefill_lazysizes" value="1" ' . checked( 1, get_option( 'wr3x_picturefill_lazysizes' ), false ) . '/>'; $html .= __( '
Retina images will not be loaded until the visitor gets close to them. HTML will be rewritten and the lazysizes script will be also loaded. The result will be a faster website for everyone, that consumes less bandwidth.', 'wp-retina-3x' ); echo $html; } function admin_picturefill_noscript_callback( $args ) { $value = get_option( 'wr3x_picturefill_noscript', null ); $html = ''; $html .= __( '
Only the browsers with src-set support will display Retina images. You can also choose this if you want to load the Picturefill Polyfill script manually or if it is already loaded by your theme.', 'wp-retina-3x' ); echo $html; } function admin_picturefill_css_background_callback( $args ) { $value = get_option( 'wr3x_picturefill_css_background', null ); $html = 'is_registered(), false, false ) . ' type="checkbox" id="wr3x_picturefill_css_background" name="wr3x_picturefill_css_background" value="1" ' . checked( 1, get_option( 'wr3x_picturefill_css_background' ), false ) . '/>'; $html .= __( '
In your HTML, inline CSS Background will be replaced by the Retina version of the image.', 'wp-retina-3x' ); echo $html; } function admin_hide_retina_column_callback( $args ) { $value = get_option( 'wr3x_hide_retina_column', null ); $html = ''; $html .= __( '
Hide the Retina Column in the Med