Skip to content

Commit

Permalink
[Version] v1.7.2
Browse files Browse the repository at this point in the history
  • Loading branch information
hi-hai committed Jan 5, 2018
1 parent c0df03c commit 4a39da4
Show file tree
Hide file tree
Showing 8 changed files with 288 additions and 125 deletions.
4 changes: 2 additions & 2 deletions litespeed-cache/admin/tpl/image_optimization.php
Original file line number Diff line number Diff line change
Expand Up @@ -191,10 +191,10 @@

<br />
<a href="<?php echo LiteSpeed_Cache_Utility::build_url( LiteSpeed_Cache::ACTION_IAPI, LiteSpeed_Cache_Admin_API::TYPE_RESET_KEY ) ; ?>" class="litespeed-btn-warning">
<?php echo __( 'Reset The IAPI Key', 'litespeed-cache' ) ; ?>
<?php echo __( 'Reset IAPI Key', 'litespeed-cache' ) ; ?>
</a>
<span class="litespeed-desc">
<?php echo __( 'If the home URL or domain is changed, this action is needed to reset your current IAPI key before next request.', 'litespeed-cache' ) ; ?>
<?php echo __( 'The current IAPI key must be reset after changing home URL or domain before making any further optimization requests.', 'litespeed-cache' ) ; ?>
</span>

<br />
Expand Down
17 changes: 10 additions & 7 deletions litespeed-cache/admin/tpl/manage/manage_cdn.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,10 @@
<p>
<b><?php echo __( 'Development Mode', 'litespeed-cache' ) ; ?>:</b>
<a href="<?php echo LiteSpeed_Cache_Utility::build_url( LiteSpeed_Cache::ACTION_CDN, LiteSpeed_Cache_CDN::TYPE_CLOUDFLARE_SET_DEVMODE_ON ) ; ?>" class="litespeed-btn-warning">
<?php echo __( 'Set To ON', 'litespeed-cache' ) ; ?>
<?php echo __( 'Turn ON', 'litespeed-cache' ) ; ?>
</a>
<a href="<?php echo LiteSpeed_Cache_Utility::build_url( LiteSpeed_Cache::ACTION_CDN, LiteSpeed_Cache_CDN::TYPE_CLOUDFLARE_SET_DEVMODE_OFF ) ; ?>" class="litespeed-btn-warning">
<?php echo __( 'Set to OFF', 'litespeed-cache' ) ; ?>
<?php echo __( 'Turn OFF', 'litespeed-cache' ) ; ?>
</a>
<a href="<?php echo LiteSpeed_Cache_Utility::build_url( LiteSpeed_Cache::ACTION_CDN, LiteSpeed_Cache_CDN::TYPE_CLOUDFLARE_GET_DEVMODE ) ; ?>" class="litespeed-btn-success">
<?php echo __( 'Check Status', 'litespeed-cache' ) ; ?>
Expand All @@ -45,26 +45,29 @@
else {
$expired_at = $curr_status[ 'devmode_expired' ] - time() ;
$expired_at = LiteSpeed_Cache_Utility::readable_time( $expired_at, 3600 * 3, false ) ;
echo sprintf( __( 'Current status is %1$s till %2$s.', 'litespeed-cache' ), '<code>' . strtoupper( $curr_status[ 'devmode' ] ) . '</code>', '<code>' . $expired_at . '</code>' ) ;
?>
<?php echo sprintf( __( 'Current status is %s.', 'litespeed-cache' ), '<code>' . strtoupper( $curr_status[ 'devmode' ] ) . '</code>' ) ; ?>
<?php echo sprintf( __( 'Development mode will be automatically turned off in %s.', 'litespeed-cache' ), '<code>' . $expired_at . '</code>' ) ; ?>
<?php
}
?>
</span>
<?php endif ; ?>

<p class="litespeed-desc">
<?php echo __( 'Temporarily bypass Cloudflare cache allowing you to see changes to your origin server in realtime.', 'litespeed-cache' ) ; ?>
<?php echo __( 'Development Mode lasts for three hours and then automatically turns off.', 'litespeed-cache' ) ; ?>
<?php echo __( 'Temporarily bypass Cloudflare cache. This allows changes to the origin server to be seen in realtime.', 'litespeed-cache' ) ; ?>
<?php echo __( 'Development Mode will be turned off automatically after three hours.', 'litespeed-cache' ) ; ?>
<a href="https://support.cloudflare.com/hc/en-us/articles/200168246" target="_blank"><?php echo __('Learn More', 'litespeed-cache') ; ?></a>
</p>
</p>

<p>
<b><?php echo __( 'Purge', 'litespeed-cache' ) ; ?>:</b>
<b><?php echo __( 'Cloudflare Cache', 'litespeed-cache' ) ; ?>:</b>
<?php if ( ! $cf_on ) : ?>
<a href="#" class="litespeed-btn-default disabled">
<?php else : ?>
<a href="<?php echo LiteSpeed_Cache_Utility::build_url( LiteSpeed_Cache::ACTION_CDN, LiteSpeed_Cache_CDN::TYPE_CLOUDFLARE_PURGE_ALL ) ; ?>" class="litespeed-btn-danger">
<?php endif ; ?>
<?php echo __( 'Purge Everything on Cloudflare', 'litespeed-cache' ) ; ?>
<?php echo __( 'Purge Everything', 'litespeed-cache' ) ; ?>
</a>
</p>
8 changes: 4 additions & 4 deletions litespeed-cache/admin/tpl/setting/settings_cdn.php
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@

<div class="litespeed-warning">
<?php echo __('NOTE:', 'litespeed-cache'); ?>
<?php echo __( 'If multiple CDN paths are configured with the same settings, the last one will overwrite the others.', 'litespeed-cache' ) ; ?>
<?php echo __( 'If multiple CDN paths are configured with the same settings, the last one will override the others.', 'litespeed-cache' ) ; ?>
</div>

<div class="litespeed-desc">
Expand All @@ -108,7 +108,7 @@
<?php echo __( 'Serve all JavaScript files through the CDN. This will affect all enqueued WP JavaScript files.', 'litespeed-cache' ) ; ?>

<br />
<b><?php echo __( 'Include File Types', 'litespeed-cache' ) ; ?></b>
<b><?php echo __( 'Include File Types', 'litespeed-cache' ) ; ?></b>:
<?php echo __( 'Static file type links to be replaced by CDN links.', 'litespeed-cache' ) ; ?>
<?php echo __('One per line.', 'litespeed-cache'); ?>
<?php echo sprintf( __( 'This will affect all tags containing attributes: %s %s %s.', 'litespeed-cache' ), '<code>src=""</code>', '<code>data-src=""</code>', '<code>href=""</code>' ) ; ?>
Expand Down Expand Up @@ -174,8 +174,8 @@
<td>
<?php $this->build_switch( LiteSpeed_Cache_Config::OPID_CDN_CLOUDFLARE ) ; ?>
<div class="litespeed-desc">
<?php echo __( 'Turn this on if you want to use Cloudflare API functionality.', 'litespeed-cache' ) ; ?>
<?php echo sprintf( __( 'Go to %1$s to <a %2$s>manage it</a>.', 'litespeed-cache' ), '<code>' . __( 'Manage', 'litespeed-cache' ) . '</code> -&gt; <code>' . __( 'CDN', 'litespeed-cache' ) . '</code>', 'href="admin.php?page=lscache-dash#cdn"' ) ; ?>
<?php echo __( 'Use Cloudflare API functionality.', 'litespeed-cache' ) ; ?>
<?php echo sprintf( __( 'This can be managed from <a %2$s>%1$s</a>.', 'litespeed-cache' ), '<b>' . __( 'Manage', 'litespeed-cache' ) . '</b> -&gt; <b>' . __( 'CDN', 'litespeed-cache' ) . '</b>', 'href="admin.php?page=lscache-dash#cdn"' ) ; ?>
</div>
<div class="litespeed-cdn-mapping-block">
<div class='litespeed-child-col'>
Expand Down
2 changes: 1 addition & 1 deletion litespeed-cache/inc/litespeed-cache.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ class LiteSpeed_Cache
private static $_instance ;

const PLUGIN_NAME = 'litespeed-cache' ;
const PLUGIN_VERSION = '1.7.1.1' ;
const PLUGIN_VERSION = '1.7.2' ;

const PAGE_EDIT_HTACCESS = 'lscache-edit-htaccess' ;

Expand Down
2 changes: 1 addition & 1 deletion litespeed-cache/inc/utility.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ public static function readable_time( $seconds_or_timestamp, $timeout = 3600, $b
$res .= $seconds . 's' ;
}

$res = sprintf( $backward ? __( ' %s ago', 'litespeed-cache' ) : __( ' %s later', 'litespeed-cache' ), $res ) ;
$res = $backward ? sprintf( __( ' %s ago', 'litespeed-cache' ), $res ) : $res ;

return $res ;
}
Expand Down
Loading

0 comments on commit 4a39da4

Please sign in to comment.