This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$reboot | |
bash: /sbin/reboot: Input/output error | |
$shutdown -r now | |
bash: /sbin/shutdown: Input/output error | |
# | |
# if the above reboot commands doesn't work try either forced reboot or shutdown | |
# |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* Disable All WP updates: core, plugins themes and notifications */ | |
add_action('admin_menu','wphidenag'); | |
function wphidenag() { | |
remove_action( 'admin_notices', 'update_nag', 3 ); | |
} | |
remove_action('load-update-core.php','wp_update_plugins'); | |
add_filter('pre_site_transient_update_plugins','__return_null'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
#****************************************************** | |
# | |
# THIS SCRIPT IS USED TO VERIFY .HTACCESS LIBWWW-PERL BLOCKING | |
# you need to add the code to .htaccess to block perl libwww | |
# | |
# 1. add the following code to .htaccess | |
# inside <IfModule mod_rewrite.c> after RewriteEngine On | |
# like the example bellow |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* send logged off users to maintenance - comment to disable*/ | |
/* sometimes reg users sessions expire, need to comment temporarily*/ | |
function maintenance_redirect(){ | |
if( !is_user_logged_in() ){ | |
wp_redirect( site_url( 'em-construcao.html' ), 302 ); | |
exit(); | |
} | |
} | |
add_action( 'init', 'maintenance_redirect' ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// set max post revisions | |
define(, 5); | |
//(or) | |
/** Disable Revision once for all*/ | |
define('WP_POST_REVISIONS', false ); | |
//(or) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Customize the WP Logo, on login page; Replace it with your clients logo | |
add_action('login_head', 'my_custom_login_page'); | |
function my_custom_login_page() { | |
echo '<style type="text/css"> | |
h1 a { | |
background: url('.get_bloginfo('template_directory').'-child/img/logo.png) no-repeat center center !important; | |
width: 200px !important; } | |
.login #login_error{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Code to remove the WP Logo and Submenu from the Admin | |
add_action( 'wp_before_admin_bar_render', 'remove_logo_and_submenu' ); | |
function remove_logo_and_submenu() { | |
global $wp_admin_bar; | |
$wp_admin_bar->remove_menu('wp-logo'); | |
$wp_admin_bar->remove_menu('about'); | |
$wp_admin_bar->remove_menu('wporg'); | |
$wp_admin_bar->remove_menu('documentation'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Remove or Replace the Update WP footer link | |
add_filter('update_footer', remove_admin_footer_upgrade, 1000); | |
function remove_admin_footer_upgrade($footer_text =''){ | |
return 'your message'; | |
} | |
// Remove or Replace the Powered By text | |
add_filter('admin_footer_text', 'remove_footer_admin'); |
NewerOlder