Making changes to your website can be risky if you don’t have a firm grasp on the structure supporting those changes. For instance, changing your CSS file is relatively easy, but if you’re not familiar with CSS, you might make a mistake that “breaks” your site. Below you’ll find a list of 5 common WordPress tweaks with tips to keep your site intact.
1. Removing all page titles from displaying
By default, most WordPress themes will display the page title at the top of each page. The page title is displayed in search results and appears in the top of the browser window. Your page titles are important to set, but there are times when you might not want your titles to appear at the top of each page.
To remove all page titles from appearing at the top of your pages, find the HTML in your theme’s template that displays titles and delete the markup. It sounds simple, but there are a couple of precautions.
First, all edits should be made to a child theme rather than your main theme. Editing a child theme ensures your changes won’t be overridden during a future theme update.
2. Resetting a user password directly in the database
Knowing how to reset user passwords directly in the database is crucial. Say your admin credentials are compromised and a hacker gains access, changes the admin password, and disables the login page. To revoke access, you can change the password directly in the database.
If you’ve never used phpMyAdmin, it’s going to be new territory for you. However, WP Beginner has a thorough guide to walk you through the process. In a nutshell, WordPress user names and passwords are stored in a table titled “wp_users” and you can edit data directly in that table.
To be extra cautious, change the user email first to make sure you have full control over lost password requests that might be sent if the hacker figures out you’ve changed the password. Once the user email is secured, change the password, and finally, change the username.
As a bonus tip, make your WordPress user names resemble a complex password rather than using dictionary words. You can always customize the way your username is displayed in the admin panel.
3. Replacing text in your content and database
If you ever need to replace multiple instances of the same text in your database, you’ll need a good search and replace plugin. You might run into this need during a site transfer or if you’re batch editing plugin or theme files and you accidentally apply a typo site-wide.
There are several good search and replace plugins listed here. Before downloading any of these, check the reviews and choose a plugin that has been recently updated.
4. Forcing SSL
SSL is now considered the standard, although many sites still use the http protocol. To force SSL for your site, first you need an SSL certificate. Many hosting companies now provide SSL for free, so check with your host before buying a certificate.
Next, you’ll need to edit your wp-config.php file located in the root directory of your WordPress installation. Follow these instructions under item #2 from Smashing Magazine to force your site to use SSL for all visitors.
Once you’ve forced SSL, use your search and replace tool to find all instances of internal links using http and change them to https.
5. Optimizing your database
Each time you publish an update to a page or post, WordPress keeps the old version in the database. WordPress is designed to keep a revision history for your convenience. These revisions aren’t a big deal if you don’t make frequent updates. However, accumulating multiple post revisions over time will slow down your database. To solve this problem, you need a plugin to delete the majority of old post revisions.
One of the top plugins for this purpose is Optimize Database after Deleting Revisions. This plugin will schedule automatic deletions at certain intervals and you can specify how many revisions you would like to keep available. For example, you can set the plugin to keep the last 5 revisions and delete the rest every Sunday at midnight.
Regularly backup your database
Keep a regular backup of your WordPress database in case you accidentally mess up your site. Database backups are imperative; even pros keep regular backups. You never know when you’ll need it.
Jenna Cyprus is a freelance writer from Renton, WA who is particularly interested in travel, nature, and parenting. Follow her on Twitter.