Skip to content

Instantly share code, notes, and snippets.

View VirtuBox's full-sized avatar
🚀
Back to work

VirtuBox VirtuBox

🚀
Back to work
View GitHub Profile
@VirtuBox
VirtuBox / .htaccess
Created January 8, 2020 17:16 — forked from seoagentur-hamburg/.htaccess
UPDATE 2019/07: Perfect .htaccess file for highspeed and security. You can use it for every WordPress-Website without problems. Highspeed and Security - testet on hundreds of Websites. If you are using a WordPress Multisite, change the last part of this file.
########################################################################
# OPTIMAL .htaccess FILE FOR SPEED AND SECURITY @Version 2019
# ----------------------------------------------------------------------
# @Author: Andreas Hecht
# @Author URI: https://andreas-hecht.com
# License: GNU General Public License v2 or later
# License URI: http://www.gnu.org/licenses/gpl-2.0.html
########################################################################
@VirtuBox
VirtuBox / wordpress-hack.md
Created November 6, 2019 14:45 — forked from andersevenrud/wordpress-hack.md
wordpress-hack.md

Wordpress is a very popular target for hackers. They normally get in with holes found in plugins, themes or in wordpress core.

Prevention methods

An up-to-date installation (including plugins and themes) is crutial!

Hardening Wordpress is sadly not a part of the standard installation documentation, but they have a guide available in the "codex": http://codex.wordpress.org/Hardening_WordPress

Removing unused plugins and users, setting htpasswd and/or ip-whitelisting in //wp-admin// also should be considered.

@VirtuBox
VirtuBox / .gitignore
Created April 18, 2019 19:27 — forked from salcode/.gitignore
Please see https://salferrarello.com/wordpress-gitignore/ for the canonical version of this WordPress .gitignore file. Note: I do not receive notifications for comments here (because GitHub does not send notifications on Gists)
# -----------------------------------------------------------------
# .gitignore for WordPress @salcode
# ver 20180808
#
# From the root of your project run
# curl -O https://gist.githubusercontent.com/salcode/b515f520d3f8207ecd04/raw/.gitignore
# to download this file
#
# By default all files are ignored. You'll need to whitelist
# any mu-plugins, plugins, or themes you want to include in the repo.
@VirtuBox
VirtuBox / hide-admin-notices.php
Created January 30, 2019 07:07 — forked from digisavvy/hide-admin-notices.php
hide admin notices in WordPress.
add_action('admin_enqueue_scripts', 'ds_admin_theme_style');
add_action('login_enqueue_scripts', 'ds_admin_theme_style');
function ds_admin_theme_style() {
if (!current_user_can( 'manage_options' )) {
echo '<style>.update-nag, .updated, .error, .is-dismissible { display: none; }</style>';
}
}