Helper Wordpress

Helper Wordpress

Wordpress can be fast. Very fast. Really :)

Customization WordPress before installation

Customization WordPress before installation

Few people know that some customization WordPress you can make before its installation. It is enough to add a few lines in the file wp-config.php. The proposed settings can enhance the safety and convenience of working with WordPress, as well as reduce the burden on database.

Customization WordPress security

Database prefix

If WordPress (or some plugin) have a security flaw known as “SQL injection”, evilminded can be easily use the default prefixes. They can be change or delete your WordPress database. However, if you have a different table prefix than the default (wp_), they must be to know that prefix, right?

While setting up a new website, either change the default value. You can do this WordPress customization on the installation page or in the wp-config.php file, change the line below:

$table_prefix = 'wooh00yeah_';

Beware: If you want to make this work in an existing WordPress site, dont need just change the prefix on the wp-config.php file. Because in this case you’ll can get database connection errors. You should use a plugin for that to change the wp-config.php file AND the database tables AND some specific values inside those tables. I recommend the DB Prefix Change plugin.

Security Keys

One of the most relevant precautions for WordPress – it is the replacement of security keys on a random values. Find in your file wp-config.php this lines

define('AUTH_KEY', 'put your unique phrase here');
define('SECURE_AUTH_KEY', 'put your unique phrase here');
define('LOGGED_IN_KEY', 'put your unique phrase here');
define('NONCE_KEY', 'put your unique phrase here');
define('AUTH_SALT', 'put your unique phrase here');
define('SECURE_AUTH_SALT', 'put your unique phrase here');
define('LOGGED_IN_SALT', 'put your unique phrase here');
define('NONCE_SALT', 'put your unique phrase here');

Then open Copy the generated keys and insert them instead of the default. Beware: can`t to make this customization in an existing WordPress site, it must be do before installation.

Editing files

WordPress default allows edit files of plug-ins or templates from the admin panel.
And if you have access to a panel of several people, respectively, increases the chance of breaking the site.
To disable the ability to edit files add in wp-config.php the following line:


Customization WordPress database

Following 3 lines can keep around 20% of your wp_post table. Your database will be happy and I think, this customization must be before each WordPress installation.

The revisions feature for posts is enabled by default, but can lead to significant database bloat. Revisions are there so you can revert to a previous version of a post if you need to. If you don’t plan on using revisions to check the “earlier versions” of your posts, you definitely should disable this feature. Jast add the following line to the wp-config.php file:

define('WP_POST_REVISIONS', false );

However, if you’re fine with revisions but you’re not going to benefit from unlimited copies of your edited posts, you can limit the maximum number of revisions for each posts with this line of code:

define('WP_POST_REVISIONS', 2 );

If you sometimes work on your post for 4 hours, you might find it annoying that WordPress automatically saves the state of your post every 60 seconds. I’ll give credit that it’s not a bad thing but sometimes it’s really, really annoying. Anyways, if you want to set the autosave interval to a higher value, you can do it by defining it in the wp-config.php file like this:

define('AUTOSAVE_INTERVAL', 240 );

And about those, who have installed WordPress. The only thing that would be difficult to change – only $table_prefix. All other settings and customization in WordPress can be done after installation. You can do it right now.

Customization WordPress before installation
Customization WordPress before installation

If you have any questions – welcome to comments, certainly I`ll glad to see it and help. If you have a custom built solution(s) or you don`t have expirience in WordPress, maybe will need to reaching to WordPress Freelancer.

If the article proved helpful to you, please click on one of the buttons to share it with your friends. Thanks!

Related posts:

What’s New in WordPress 5.1

What’s New in WordPress 5.1

WordPress 5.1 available on February 21, 2019. It have name “Betty” in honoring American jazz singer Betty Carter. WordPress 5.0 had been downloaded more than 35 million times [...]
How pack and unpack archives via SSH

How pack and unpack archives via SSH

It happens, that some hosting company have inconvenient hosting control panel – and work with files is no possibility, or this feature is bad implemented / this feature [...]
Fake deals on upwork

Fake deals on upwork

This post for those freelancers who work on – the world’s largest stock exchange of freelancing. Also this post are warning about scams, hacking accounts and sending [...]

Leave a Reply

Your email address will not be published. Required fields are marked *