| Server IP : 195.130.67.5 / Your IP : 216.73.217.154 Web Server : Microsoft-IIS/10.0 System : Windows NT WEBSERVER1 10.0 build 17763 (Windows Server 2016) i586 User : IUSR ( 0) PHP Version : 7.4.19 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /inetpub/wwwroot/engineering/iimec/wp-content/themes/graphene/admin/ |
Upload File : |
<?php
/* Check authorisation */
$authorised = true;
// Check nonce
if ( ! wp_verify_nonce( $_POST['graphene-uninstall'], 'graphene-uninstall' ) ) {
$authorised = false;
}
// Check permissions
if ( ! current_user_can( 'edit_theme_options' ) ) {
$authorised = false;
}
// If the user is authorised, delete the theme's options from the database
if ( $authorised ) {
delete_option( 'graphene_settings' );
delete_transient( 'graphene-action-hooks-list' );
delete_transient( 'graphene-action-hooks' );
switch_theme( 'twentyeleven', 'twentyeleven' );
wp_cache_flush(); ?>
<div class="wrap">
<h2><?php _e( 'Uninstall Graphene', 'graphene' ); ?></h2>
<p><?php printf( __( 'Theme uninstalled. Redirecting to %s', 'graphene' ), '<a href="'.get_home_url().'/wp-admin/themes.php?activated=true">'.get_home_url().'/wp-admin/themes.php?activated=true</a>...' ); ?></p>
<script type="text/javascript">
window.location = '<?php echo get_home_url(); ?>/wp-admin/themes.php?activated=true';
</script>;
</div>
<?php
} else {
wp_die( __( 'ERROR: You are not authorised to perform that operation', 'graphene' ));
}