Plugin Directory

Changeset 1543285


Ignore:
Timestamp:
11/30/2016 11:44:59 AM (9 years ago)
Author:
ilanraid
Message:

update to version 1.2

Location:
upress-link
Files:
16 added
5 edited

Legend:

Unmodified
Added
Removed
  • upress-link/trunk/admin/css/upress-link.css

    r1176158 r1543285  
    5757
    5858.lcs_wrap {
    59     width: 73px;
     59    width: 100px;
    6060    position: relative;
    6161}
    6262.lcs_wrap .spinner {
    63     left: 50%;
     63    left: -50%;
    6464    margin-left: -10px;
    6565    position: relative;
     66}
     67.rtl .lcs_wrap .spinner {
     68    left: 50%;
    6669}
    6770
  • upress-link/trunk/admin/js/upress-link.js

    r1176158 r1543285  
    1515            spinner.fadeOut('fast', function() {
    1616                the_switch.fadeIn('fast');
    17             });
     17            }).removeClass('is-active');
    1818            return;
    1919        }
    2020        if(val === "show" || (!val && !is_shown)) {
    2121            the_switch.fadeOut('fast', function() {
    22                 spinner.fadeIn('fast');
     22                spinner.fadeIn('fast').addClass('is-active');
    2323            });
    2424            return;
     
    7373                '_nonce': upressAjax._nonce
    7474            }, function(response) {
    75                 //console.log(response);
    7675
    7776                if(response.status == "fail") {
    78                     flashErrorMessage(response.data.message);
     77                    flashErrorMessage(response.data ? response.data.message : upressAjax.requestFailed);
    7978                    self.data('noevent', true);
    8079                    if(status) {
     
    102101                '_nonce': upressAjax._nonce
    103102            }, function(response) {
    104                 //console.log(response);
    105 
    106103                if (response.status == "fail") {
    107                     flashErrorMessage(response.data.message);
     104                    flashErrorMessage(response.data ? response.data.message : upressAjax.requestFailed);
    108105                }
    109106                if(response.status == "success") {
     
    128125                '_nonce': upressAjax._nonce
    129126            }, function(response) {
    130                 console.log(response);
    131 
    132127                if (response.status == "fail") {
    133                     flashErrorMessage(response.data.message);
     128                    flashErrorMessage(response.data ? response.data.message : upressAjax.requestFailed);
    134129                }
    135130                if(response.status == "success") {
     
    155150                '_nonce': upressAjax._nonce
    156151            }, function(response) {
    157                 console.log(response);
    158 
    159152                if (response.status == "fail") {
    160153                    flashErrorMessage(response.errors_msg);
     
    186179            height: self.outerHeight()
    187180        }).find('.text').fadeOut('fast', function() {
    188             self.find('.spinner').fadeIn('fast');
     181            self.find('.spinner').addClass('is-active').fadeIn('fast');
    189182        }).end().attr('disabled', true);
    190183    };
    191184    var endAjaxSpinner = function(self) {
    192185        self.find('.spinner').fadeOut('fast', function () {
     186            $(this).removeClass('is-active');
    193187            self.find('.text').fadeIn('fast').end().css( {
    194188                width: '',
     
    234228                '_nonce': upressAjax._nonce
    235229            }, function(response) {
    236                 //console.log(response);
    237 
     230                console.log(response);
    238231                if(response.status == "success") {
    239232                    var data = response.data.data;
    240233                    self.data('noevent', true);
    241                     if(data && data.value === "1") {
     234                    if(data && data.value == "1") {
    242235                        self.lcs_on();
    243236                    } else {
     
    245238                    }
    246239                } else {
    247                     flashErrorMessage(response.data.message);
     240                    flashErrorMessage(response.data ? response.data.message : upressAjax.requestFailed);
    248241                }
    249242            }));
     
    285278                    '_nonce': upressAjax._nonce
    286279                }, function(response) {
    287                     //console.log(response);
    288 
    289280                    if(response.status == "success") {
    290281                        var data = response.data.data
     
    297288                        }
    298289                    } else {
    299                         flashErrorMessage(response.data.message);
     290                        flashErrorMessage(response.data ? response.data.message : upressAjax.requestFailed);
    300291                    }
    301292                });
  • upress-link/trunk/admin/options.php

    r1176158 r1543285  
    11<div class="wrap upress-wrap">
    2     <h2><?php _ex($this->plugin_name, 'admin page title', $this->text_domain); ?></h2>
     2    <h2><?php _ex($this->plugin_name, 'admin page title', 'upresslink'); ?></h2>
    33
    44    <?php if( $error_message ) : ?>
    5         <div class="error init-error"><p><strong><?php _e( 'uPress error:', $this->text_domain ); ?></strong> <?php echo $error_message; ?></p></div>
     5        <div class="error init-error"><p><strong><?php _e( 'uPress error:', 'upresslink' ); ?></strong> <?php echo $error_message; ?></p></div>
    66    <?php endif ?>
    77
    88    <div class="notice notice-success api-success"><p></p></div>
    9     <div class="notice notice-info no-api-key"><p><?php _e( 'You have not yet entered your API key. You must have an API key before you can use this plugin', $this->text_domain ); ?></p></div>
    10     <div class="error api-error"><p><strong><?php _e( 'uPress error:', $this->text_domain ); ?></strong> <span></span></p></div>
     9    <div class="notice notice-info no-api-key"><p><?php _e( 'You have not yet entered your API key. You must have an API key before you can use this plugin', 'upresslink' ); ?></p></div>
     10    <div class="error api-error"><p><strong><?php _e( 'uPress error:', 'upresslink' ); ?></strong> <span></span></p></div>
    1111    <p>
    1212        <?php /* translators: allowed HTML tags: <br>, <em>, <strong>, <a href='' title=''> */ ?>
    13         <?php echo wp_kses( __('uPress Link allows you to manage some of the features available in uPress.<br>You will have to generate an API key to link the plugin to your uPress account.', $this->text_domain ), array(
     13        <?php echo wp_kses( __('uPress Link allows you to manage some of the features available in uPress.<br>You will have to generate an API key to link the plugin to your uPress account.', 'upresslink' ), array(
    1414            'a' => array(
    1515                'href' => array(),
     
    2828        <table class="form-table">
    2929            <tr valign="top">
    30                 <th scope="row"><?php _e( 'uPress API Key:', $this->text_domain ); ?></th>
     30                <th scope="row"><?php _e( 'uPress API Key:', 'upresslink' ); ?></th>
    3131                <td>
    3232                    <input type="text" id="api_key" name="<?php echo $opt_name; ?>[api_key]" value="<?php echo esc_attr( $options['api_key'] ); ?>" size="80" />
    3333                    <br>
    34                     <a href="https://my.upress.co.il/account/websites" target="_blank"><?php _e( 'Go to uPress and get your API key', $this->text_domain ); ?></a>
    35                     <p><?php _e( 'Select your website from the list, then go to "Settings" tab and click "Generate API Key" button', $this->text_domain ); ?></p>
     34                    <a href="https://my.upress.co.il/account/websites" target="_blank"><?php _e( 'Go to uPress and get your API key', 'upresslink' ); ?></a>
     35                    <p><?php _e( 'Select your website from the list, then go to "Settings" tab and click "Generate API Key" button', 'upresslink' ); ?></p>
    3636                </td>
    3737            </tr>
    3838            <tr valign="top">
    39                 <th scope="row"><?php _e( 'Delete cache after post update:', $this->text_domain ); ?></th>
     39                <th scope="row"><?php _e( 'Delete cache after post update:', 'upresslink' ); ?></th>
    4040                <td>
    4141                    <input type="checkbox" name="<?php echo $opt_name; ?>[clear_post_cache]" value="1" <?php checked( $options['clear_post_cache'], '1', TRUE ); ?> size="80" />
    42                     <span class="description"><?php esc_attr_e( 'This will remove the CDN cache for the post URL so the updates will show immediately*. This is applicable only if the CDN is available and enabled.', $this->text_domain ); ?></span>
     42                    <span class="description"><?php esc_attr_e( 'This will remove the CDN cache for the post URL so the updates will show immediately*. This is applicable only if the CDN is available and enabled.', 'upresslink' ); ?></span>
    4343                </td>
    4444            </tr>
     
    4949
    5050    <hr>
    51     <h3><?php esc_attr_e( 'More actions', $this->text_domain ); ?></h3>
     51    <h3><?php esc_attr_e( 'More actions', 'upresslink' ); ?></h3>
    5252    <div class="wrap">
    53         <h4><?php esc_attr_e( 'Fix media upload path', $this->text_domain ); ?></h4>
    54         <p><?php esc_attr_e( 'Sometimes after migrating a WordPress installation the media path is not set correctly and breaks uploading media content. This will fix the issue and correct the upload path.', $this->text_domain ); ?></p>
    55         <p><button class="button-secondary media-path-fix-button" type="button" data-ajax-spinner><?php esc_attr_e( 'Run media path fix', $this->text_domain ); ?></button></p>
    56 
    57         <h4><?php esc_attr_e( 'Database search and replace', $this->text_domain ); ?></h4>
    58         <p><?php esc_attr_e( 'This will allow you to replace a text in your entire website in a simple click of a button', $this->text_domain ); ?></p>
     53        <h4><?php esc_attr_e( 'Fix media upload path', 'upresslink' ); ?></h4>
     54        <p><?php esc_attr_e( 'Sometimes after migrating a WordPress installation the media path is not set correctly and breaks uploading media content. This will fix the issue and correct the upload path.', 'upresslink' ); ?></p>
     55        <p><button class="button-secondary media-path-fix-button" type="button" data-ajax-spinner><?php esc_attr_e( 'Run media path fix', 'upresslink' ); ?></button></p>
     56
     57        <h4><?php esc_attr_e( 'Database search and replace', 'upresslink' ); ?></h4>
     58        <p><?php esc_attr_e( 'This will allow you to replace a text in your entire website in a simple click of a button', 'upresslink' ); ?></p>
    5959        <p>
    6060            <table class="form-table">
    6161                <tr valign="top">
    62                     <th scope="row"><?php esc_attr_e( 'Search:', $this->text_domain ); ?></th>
     62                    <th scope="row"><?php esc_attr_e( 'Search:', 'upresslink' ); ?></th>
    6363                    <td><input type="text" class="regular-text search-and-replace-from" /></td>
    6464                </tr>
    6565                <tr valign="top">
    66                     <th scope="row"><?php esc_attr_e( 'Replace:', $this->text_domain ); ?></th>
     66                    <th scope="row"><?php esc_attr_e( 'Replace:', 'upresslink' ); ?></th>
    6767                    <td><input type="text" class="regular-text search-and-replace-to" /></td>
    6868                </tr>
    6969            </table>
    7070
    71             <button class="button-secondary search-and-replace-button" type="button" data-ajax-spinner><?php esc_attr_e( 'Search and replace', $this->text_domain ); ?></button>
     71            <button class="button-secondary search-and-replace-button" type="button" data-ajax-spinner><?php esc_attr_e( 'Search and replace', 'upresslink' ); ?></button>
    7272        </p>
    7373    </div>
     
    8383                <div class="meta-box-sortables ui-sortable">
    8484
    85                     <div class="postbox upress-section" id="upress-tab-general" data-not-available-text="<?php _e( 'General settings not available', $this->text_domain ); ?>">
    86                         <div class="handlediv" title="<?php _e( 'Click to toggle' ); ?>"><br></div>
    87                         <div class="reload-btn"><a href="" title="<?php _e( 'Refresh section', $this->text_domain ); ?>"><span class="dashicons dashicons-update"></span></a></div>
    88                         <!-- Toggle -->
    89                         <h3 class="hndle"><span><?php _ex('General', 'section title', $this->text_domain); ?></span></h3>
     85                    <div class="postbox upress-section" id="upress-tab-general" data-not-available-text="<?php _e( 'General settings not available', 'upresslink' ); ?>">
     86                        <div class="handlediv" title="<?php _e( 'Click to toggle' ); ?>"><br></div>
     87                        <div class="reload-btn"><a href="" title="<?php _e( 'Refresh section', 'upresslink' ); ?>"><span class="dashicons dashicons-update"></span></a></div>
     88                        <!-- Toggle -->
     89                        <h3 class="hndle"><span><?php _ex('General', 'section title', 'upresslink'); ?></span></h3>
    9090                        <div class="inside">
    9191                            <table class="form-table">
    9292                                <tr valign="top">
    93                                     <th scope="row"><?php _e( 'Auto Update', $this->text_domain ); ?></th>
     93                                    <th scope="row"><?php _e( 'Auto Update', 'upresslink' ); ?></th>
    9494                                    <td>
    9595                                        <input type="checkbox" class="switch" data-action="auto_update">
    96                                         <span class="description"><?php esc_attr_e( 'uPress can make sure your WordPress is up to date with its automatic core updates.', $this->text_domain ); ?></span>
    97                                     </td>
    98                                 </tr>
    99                                 <tr valign="top">
    100                                     <th scope="row"><?php _e( 'Auto Redirect WWW', $this->text_domain ); ?></th>
     96                                        <span class="description"><?php esc_attr_e( 'uPress can make sure your WordPress is up to date with its automatic core updates.', 'upresslink' ); ?></span>
     97                                    </td>
     98                                </tr>
     99                                <tr valign="top">
     100                                    <th scope="row"><?php _e( 'Auto Redirect WWW', 'upresslink' ); ?></th>
    101101                                    <td>
    102102                                        <input type="checkbox" class="switch" data-action="auto_redirect_www">
    103                                         <span class="description"><?php esc_attr_e( 'Automatically redirect your domain to the www.domain.name counterpart.', $this->text_domain ); ?></span>
    104                                     </td>
    105                                 </tr>
    106                                 <tr valign="top">
    107                                     <th scope="row"><?php _e( 'Web Firewall', $this->text_domain ); ?></th>
     103                                        <span class="description"><?php esc_attr_e( 'Automatically redirect your domain to the www.domain.name counterpart.', 'upresslink' ); ?></span>
     104                                    </td>
     105                                </tr>
     106                                <tr valign="top">
     107                                    <th scope="row"><?php _e( 'Web Firewall', 'upresslink' ); ?></th>
    108108                                    <td>
    109109                                        <input type="checkbox" class="switch" data-action="web_firewall">
    110                                         <span class="description"><?php esc_attr_e( 'Web Firewall block tens of thousands of known attacks, and we update our system every day to ensure even the newest attacks are blocked right away. Our tools will allow you to easily fix any number of hacks and exploits.', $this->text_domain ); ?></span>
    111                                     </td>
    112                                 </tr>
     110                                        <span class="description"><?php esc_attr_e( 'Web Firewall block tens of thousands of known attacks, and we update our system every day to ensure even the newest attacks are blocked right away. Our tools will allow you to easily fix any number of hacks and exploits.', 'upresslink' ); ?></span>
     111                                    </td>
     112                                </tr>
     113                                <tr valign="top">
     114                                    <th scope="row"><?php _e( 'Development Mode', 'upresslink' ); ?></th>
     115                                    <td>
     116                                        <input type="checkbox" class="switch" data-action="dev_mode">
     117                                        <span class="description"><?php esc_attr_e( 'Disable all types of caches and enable error display.', 'upresslink' ); ?></span>
     118                                    </td>
     119                                </tr>
    113120                            </table>
    114121                        </div>
     
    117124                    <!-- .postbox -->
    118125
    119                     <div class="postbox upress-section" id="upress-tab-cdn" data-check-availability="cdn_available" data-not-available-text="<?php _e( 'CDN settings not available', $this->text_domain ); ?>">
    120                         <div class="handlediv" title="<?php _e( 'Click to toggle' ); ?>"><br></div>
    121                         <div class="reload-btn"><a href="" title="<?php _e( 'Refresh section', $this->text_domain ); ?>"><span class="dashicons dashicons-update"></span></a></div>
    122                         <!-- Toggle -->
    123                         <h3 class="hndle"><span><?php _ex('CDN Network', 'section title', $this->text_domain); ?></span></h3>
    124                         <div class="inside">
    125                             <p><?php esc_attr_e( 'Our CDN (Content Delivery Network) option will make sure your images, CSS, and other files get served from one of a dozen datacenters around the world, whichever is closest to where each visitor is located.', $this->text_domain ); ?></p>
     126                    <div class="postbox upress-section" id="upress-tab-cdn" data-check-availability="cdn_available" data-not-available-text="<?php _e( 'CDN settings not available', 'upresslink' ); ?>">
     127                        <div class="handlediv" title="<?php _e( 'Click to toggle' ); ?>"><br></div>
     128                        <div class="reload-btn"><a href="" title="<?php _e( 'Refresh section', 'upresslink' ); ?>"><span class="dashicons dashicons-update"></span></a></div>
     129                        <!-- Toggle -->
     130                        <h3 class="hndle"><span><?php _ex('CDN Network', 'section title', 'upresslink'); ?></span></h3>
     131                        <div class="inside">
     132                            <p><?php esc_attr_e( 'Our CDN (Content Delivery Network) option will make sure your images, CSS, and other files get served from one of a dozen datacenters around the world, whichever is closest to where each visitor is located.', 'upresslink' ); ?></p>
    126133
    127134                            <table class="form-table">
    128135                                <tr valign="top">
    129                                     <th scope="row"><?php _e( 'Enable CDN', $this->text_domain ); ?></th>
     136                                    <th scope="row"><?php _e( 'Enable CDN', 'upresslink' ); ?></th>
    130137                                    <td>
    131138                                        <input type="checkbox" class="switch" data-action="enable_cdn">
     
    133140                                </tr>
    134141                                <tr valign="top">
    135                                     <th scope="row"><?php _e( 'Development Mode', $this->text_domain ); ?></th>
     142                                    <th scope="row"><?php _e( 'Development Mode', 'upresslink' ); ?></th>
    136143                                    <td>
    137144                                        <input type="checkbox" class="switch" data-action="enable_devmode">
    138                                         <span class="description"><?php esc_attr_e( 'Note: Development mode will automatically toggle off 3 hours after initial setup.', $this->text_domain ); ?></span>
    139                                     </td>
    140                                 </tr>
    141                                 <tr valign="top">
    142                                     <th scope="row"><?php _e( 'Minify HTML', $this->text_domain ); ?></th>
     145                                        <span class="description"><?php esc_attr_e( 'Note: Development mode will automatically toggle off 3 hours after initial setup.', 'upresslink' ); ?></span>
     146                                    </td>
     147                                </tr>
     148                                <tr valign="top">
     149                                    <th scope="row"><?php _e( 'Minify HTML', 'upresslink' ); ?></th>
    143150                                    <td>
    144151                                        <input type="checkbox" class="switch" data-action="min_html">
     
    146153                                </tr>
    147154                                <tr valign="top">
    148                                     <th scope="row"><?php _e( 'Minify CSS', $this->text_domain ); ?></th>
     155                                    <th scope="row"><?php _e( 'Minify CSS', 'upresslink' ); ?></th>
    149156                                    <td>
    150157                                        <input type="checkbox" class="switch" data-action="min_css">
     
    152159                                </tr>
    153160                                <tr valign="top">
    154                                     <th scope="row"><?php _e( 'Minify JavaScript', $this->text_domain ); ?></th>
     161                                    <th scope="row"><?php _e( 'Minify JavaScript', 'upresslink' ); ?></th>
    155162                                    <td>
    156163                                        <input type="checkbox" class="switch" data-action="min_js">
     
    158165                                </tr>
    159166                                <tr valign="top">
    160                                     <th scope="row"><?php _e( 'Cache', $this->text_domain ); ?></th>
    161                                     <td>
    162                                         <button type="button" class="button button-default" data-action="clear_cache" data-success-message="<?php _e( 'Cache cleared successfully', $this->text_domain ); ?>"><?php _e( 'Clear Cache', $this->text_domain ); ?></button>
     167                                    <th scope="row"><?php _e( 'Cache', 'upresslink' ); ?></th>
     168                                    <td>
     169                                        <button type="button" class="button button-default" data-action="clear_cache" data-success-message="<?php _e( 'Cache cleared successfully', 'upresslink' ); ?>"><?php _e( 'Clear Cache', 'upresslink' ); ?></button>
    163170                                    </td>
    164171                                </tr>
     
    169176                    <!-- .postbox -->
    170177
    171                     <div class="postbox upress-section" id="upress-tab-optimization" data-check-availability="optimization_available" data-not-available-text="<?php _e( 'Optimization settings not available', $this->text_domain ); ?>">
    172                         <div class="handlediv" title="<?php _e( 'Click to toggle' ); ?>"><br></div>
    173                         <div class="reload-btn"><a href="" title="<?php _e( 'Refresh section', $this->text_domain ); ?>"><span class="dashicons dashicons-update"></span></a></div>
    174                         <!-- Toggle -->
    175                         <h3 class="hndle"><span><?php _ex('Optimization', 'section title', $this->text_domain); ?></span></h3>
    176                         <div class="inside">
    177                             <p><?php esc_attr_e( 'Optimizes and boosts performance of your website.', $this->text_domain ); ?></p>
     178                    <div class="postbox upress-section" id="upress-tab-optimization" data-check-availability="optimization_available" data-not-available-text="<?php _e( 'Optimization settings not available', 'upresslink' ); ?>">
     179                        <div class="handlediv" title="<?php _e( 'Click to toggle' ); ?>"><br></div>
     180                        <div class="reload-btn"><a href="" title="<?php _e( 'Refresh section', 'upresslink' ); ?>"><span class="dashicons dashicons-update"></span></a></div>
     181                        <!-- Toggle -->
     182                        <h3 class="hndle"><span><?php _ex('Optimization', 'section title', 'upresslink'); ?></span></h3>
     183                        <div class="inside">
     184                            <p><?php esc_attr_e( 'Optimizes and boosts performance of your website.', 'upresslink' ); ?></p>
    178185
    179186                            <table class="form-table">
    180187                                <tr valign="top">
    181                                     <th scope="row"><?php _e( 'Enable Optimization', $this->text_domain ); ?></th>
     188                                    <th scope="row"><?php _e( 'Enable Optimization', 'upresslink' ); ?></th>
    182189                                    <td>
    183190                                        <input type="checkbox" class="switch" data-action="enable_optimization">
    184                                         <span class="description"><?php _e( 'Note: This only toggles optimization on/off. <a href="https://my.upress.co.il/account/websites">Mange all optimization settings from uPress</a>', $this->text_domain ); ?></span>
     191                                        <span class="description"><?php _e( 'Note: This only toggles optimization on/off. <a href="https://my.upress.co.il/account/websites">Mange all optimization settings from uPress</a>', 'upresslink' ); ?></span>
    185192                                    </td>
    186193                                </tr>
     
    201208                        <div class="handlediv" title="<?php _e( 'Click to toggle' ); ?>"><br></div>
    202209                        <!-- Toggle -->
    203                         <h3 class="hndle"><span><?php _ex('Resources and more information', 'section title', $this->text_domain); ?></span></h3>
     210                        <h3 class="hndle"><span><?php _ex('Resources and more information', 'section title', 'upresslink'); ?></span></h3>
    204211                        <div class="inside">
    205212                            <ul>
    206                                 <li><a href="https://upress.co.il"><?php _e( 'uPress Homepage', $this->text_domain ); ?></a></li>
    207                                 <li><a href="https://my.upress.co.il"><?php _e( 'Login to uPress', $this->text_domain ); ?></a></li>
     213                                <li><a href="https://www.upress.co.il"><?php _e( 'uPress Homepage', 'upresslink' ); ?></a></li>
     214                                <li><a href="https://my.upress.co.il"><?php _e( 'Login to uPress', 'upresslink' ); ?></a></li>
    208215                            </ul>
    209216                        </div>
     
    227234
    228235<hr>
    229 <span class="description"><?php esc_attr_e( '*Updates are queued and refreshed 1 minute after the update.', $this->text_domain ); ?></span>
     236<span class="description"><?php esc_attr_e( '*Updates are queued and refreshed 1 minute after the update.', 'upresslink' ); ?></span>
  • upress-link/trunk/readme.txt

    r1176161 r1543285  
    33Tags: upress,hosting,companion,link,manager,cdn,optimization,performance
    44Requires at least: 4.0
    5 Tested up to: 4.1.1
     5Tested up to: 4.6.1
    66Stable tag: 1.1.0
    77License: GPL-2.0+
     
    5353
    5454== Changelog ==
     55= 1.2 =
     561. Added option to activate development mode
     571. Fixed spinner not showing at newer WordPress versions
    5558= 1.1 =
    56591. Added option to fix media upload path
  • upress-link/trunk/upress-link.php

    r1176168 r1543285  
    1717 * Plugin URI:        http://upress.co.il
    1818 * Description:       uPress Link is a companion plugin for the WordPress hosting manager at https://upress.co.il
    19  * Version:           1.1.0
     19 * Version:           1.2.0
    2020 * Author:            Drubit Raid LTD.
    2121 * Author URI:        http://upress.co.il
     
    2929    die;
    3030}
    31 define( 'UPL_VERSION', '1.1.0' );
     31define( 'UPL_VERSION', '1.2.0' );
    3232define( 'UPL_PATH', dirname( __FILE__ ) );
    3333define( 'UPL_PATH_INCLUDES', dirname( __FILE__ ) . '/includes' );
     
    3939
    4040define( 'UPRESS_API_BASE', 'https://my.upress.co.il/api/wordpress/' );
     41define( 'UPRESS_USER_AGENT', 'uPress-Link/' . UPL_VERSION );
    4142
    4243class uPress_Link {
     
    6768    /* ****************************************** */
    6869    function upl_admin_menu() {
    69         add_options_page( _x($this->plugin_name, 'admin page title', $this->text_domain), _x($this->plugin_name, 'admin page menu item', $this->text_domain), 'manage_options', $this->plugin_slug, array( $this, 'upl_admin_view' ) );
     70        add_options_page( _x($this->plugin_name, 'admin page title', 'upresslink'), _x($this->plugin_name, 'admin page menu item', 'upresslink'), 'manage_options', $this->plugin_slug, array( $this, 'upl_admin_view' ) );
    7071    }
    7172    function upl_admin_init() {
     
    8889                'on' => __( 'ON' ),
    8990                'off' => __( 'OFF' ),
    90                 'requestSuccess' => __( 'Operation completed successfully', $this->text_domain )
     91                'requestSuccess' => __( 'Operation completed successfully', 'upresslink' ),
     92                'requestFailed' => __( 'Operation could not be completed at this time', 'upresslink' ),
    9193            )
    9294        );
     
    114116                'timeout' => 45,
    115117                'blocking' => true,
     118                'user-agent' => UPRESS_USER_AGENT,
    116119                'body' => array(
    117120                    'api_key' => $options['api_key']
     
    165168            'timeout' => 45,
    166169            'blocking' => true,
     170            'user-agent' => UPRESS_USER_AGENT,
    167171            'body' => array(
    168172                'api_key' => $api_key,
     
    343347            'debug' => $wpdb,
    344348            'time' => $time,
    345             'success_msg' => sprintf( __( 'Replace completed for the text "%s" which was replaced by "%s". %d tables scanned with %d total rows. Replacement took %f seconds.', $this->text_domain ),
     349            'success_msg' => sprintf( __( 'Replace completed for the text "%s" which was replaced by "%s". %d tables scanned with %d total rows. Replacement took %f seconds.', 'upresslink' ),
    346350                $search, $replace, $report[ 'tables' ], $report[ 'rows' ], $report[ 'change' ], $report[ 'updates' ], $time ),
    347351            'errors_msg' => $errors
     
    368372                'timeout' => 45,
    369373                'blocking' => true,
     374                'user-agent' => UPRESS_USER_AGENT,
    370375                'body' => array(
    371376                    'api_key' => $options['api_key'],
Note: See TracChangeset for help on using the changeset viewer.