| Server IP : 188.114.97.4 / Your IP : 104.23.243.200 Web Server : Apache/2.4.59 (Debian) System : Linux EDL-STRETCH 4.19.0-27-amd64 #1 SMP Debian 4.19.316-1 (2024-06-25) x86_64 User : edlftp ( 1002) PHP Version : 7.4.33 Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare, MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /home/nicolasj/www/b2b.ecoledelangues.be/wp-content/plugins/string-locator/ |
Upload File : |
<?php
if ( ! defined( 'ABSPATH' ) ) {
die();
}
$this_url = admin_url( ( is_multisite() ? 'network/admin.php' : 'tools.php' ) . '?page=string-locator' );
$search_string = '';
$search_location = '';
$search_regex = false;
if ( isset( $_POST['string-locator-string'] ) ) {
$search_string = $_POST['string-locator-string'];
}
if ( isset( $_POST['string-locator-search'] ) ) {
$search_location = $_POST['string-locator-search'];
}
if ( isset( $_GET['restore'] ) ) {
$restore = unserialize( get_option( 'string-locator-search-overview' ) );
$search_string = $restore->search;
$search_location = $restore->directory;
$search_regex = String_Locator::absbool( $restore->regex );
}
?>
<div class="wrap">
<h2>
<?php esc_html_e( 'String Locator', 'string-locator' ); ?>
</h2>
<form action="<?php echo esc_url( $this_url ); ?>" method="post" id="string-locator-search-form">
<label for="string-locator-search"><?php esc_html_e( 'Search through', 'string-locator' ); ?></label>
<select name="string-locator-search" id="string-locator-search">
<optgroup label="<?php esc_attr_e( 'Core', 'string-locator' ); ?>">
<option value="core"><?php esc_html_e( 'The whole WordPress directory', 'string-locator' ); ?></option>
<option value="wp-content"><?php esc_html_e( 'Everything under wp-content', 'string-locator' ); ?></option>
</optgroup>
<optgroup label="<?php esc_attr_e( 'Themes', 'string-locator' ); ?>">
<?php echo String_Locator::get_themes_options( $search_location ); ?>
</optgroup>
<?php if ( String_Locator::has_mu_plugins() ) : ?>
<optgroup label="<?php esc_attr_e( 'Must Use Plugins', 'string-locator' ); ?>">
<?php echo String_Locator::get_mu_plugins_options( $search_location ); ?>
</optgroup>
<?php endif; ?>
<optgroup label="<?php esc_attr_e( 'Plugins', 'string-locator' ); ?>">
<?php echo String_Locator::get_plugins_options( $search_location ); ?>
</optgroup>
</select>
<label for="string-locator-string"><?php esc_html_e( 'Search string', 'string-locator' ); ?></label>
<input type="text" name="string-locator-string" id="string-locator-string" value="<?php echo esc_attr( $search_string ); ?>" />
<label><input type="checkbox" name="string-locator-regex" id="string-locator-regex"<?php echo ( $search_regex ? ' checked="checked"' : '' ); ?>'> <?php esc_html_e( 'RegEx search', 'string-locator' ); ?></label>
<p>
<input type="submit" name="submit" id="submit" class="button button-primary" value="<?php esc_html_e( 'Search', 'string-locator' ); ?>">
<a href="<?php echo esc_url( $this_url . '&restore=true' ); ?>" class="button button-primary"><?php esc_html_e( 'Restore last search', 'string-locator' ); ?></a>
</p>
</form>
<div class="notices"></div>
<div class="string-locator-feedback hide">
<progress id="string-locator-search-progress" max="100"></progress>
<span id="string-locator-feedback-text"><?php esc_html_e( 'Preparing search…', 'string-locator' ); ?></span>
</div>
<div class="table-wrapper">
<?php
if ( isset( $_GET['restore'] ) ) {
$items = maybe_unserialize( get_option( 'string-locator-search-history', array() ) );
echo String_Locator::prepare_full_table( $items, array( 'restore' ) );
}
else {
echo String_Locator::prepare_full_table( array() );
}
?>
</div>
</div>