Need Help? Start Here
Many people install plugins to do every small task in WordPress. This can really slow down your site!
Instead of adding lots of plugins, many times you can just add a few lines of code to your functions.php file to achieve exactly the same result.
That’s the purpose of this site – to show you some of these things that you can do! This obviously requires that you have some technical know-how, but I’m going to give some valuable tips to help you!
Most of the code on this site is intended to be added to your functions.php.
Functions.php is a file that exists in the theme directory in WordPress. It is a script that allows you to add or change the inner workings of your blog. There is some risk in editing this file. If you have a syntax error in your code, there’s a good chance it will take your site down (until you correct the error).
However, there are ways to reduce this risk. The best of course is to set up a local LAMP web server and clone your blog to there. There are plenty of guides on the internet to help you with that if you want to.
It’s also possible to work on the live server if you set yourself up with a few decent development tools.
There are two main tools you need, an FTP client and a text-editor. There’s dozens of different choices but I’ll describe just a couple that are cross-platform and free or good value.
Filezilla is a free FTP client. It’s available on Windows, Mac OS-X and Linux. This will allow you to upload and download files from your server. You need this for getting access to and editing your functions.php file. https://filezilla-project.org/
There is a file editor built into the WordPress admin but it’s truly awful. Do not use it! There is no syntax formatting and no revisions. This makes mistakes much more likely!!
The best way is using a text editor like Sublime Text (which is what I use for local development).
Sublime Text is a fabulous text editor with syntax highlighting. Again, it’s available for Windows, OS-X and Linux. It’s not free but it does have an everlasting, full featured ‘trial mode’. http://www.sublimetext.com/
I also use a service called Code Anywhere. I use this mainly when I’m out and about and can’t use my main computer. This is a great alternative to both pieces of software above as it includes both an FTP client and editor.
I highly recommend Code Anywhere. It has an almost identical text editor to Sublime Text with the bonus that you can operate it in any browser! You can code from your tablet, laptop or internet cafe and all your files will be in the same state as you move between your devices! Super COOL! It also has file revisions and a test VPS feature.
Before you do anything with your functions.php, you should create a CHILD THEME and edit the functions.php in your child theme directory!!
DO NOT edit the functions.php in your parent theme directory. Otherwise you risk losing all your changes when the theme updates!