If you’re new to WordPress and website management in general you might be confused when someone says something like “Overwrite xxxx.php in your /library/functions folder and xxxx.css in your /skins folder“. What we mean by that is that you need to connect to your site using an FTP client, navigate to the mentioned folder and overwrite (more on how to do this later).
Sometimes we say things like “You need to make changes inside xxxx.php located in your theme root around line 100”. What we mean by that is that you need to connect to your site, navigate to that file, download it to your hard drive, edit it and upload it back. Sounds tricky – but it’s far from it.
How to connect to the server?
You’ll need two things…
-
FTP client
FTP client is a program you will use to connect to your server. We’ll be using FileZilla during this tutorial. You can download it here. -
FTP account
Most people get an FTP account from their hosting provider. In case you didn’t receive one or you forgot the information contact the hosting provider to create on for yourself.
Connecting to your server
-
Open FileZilla
-
Enter your FTP account details in the boxes at the top left corner. In most cases you can leave “Port” empty
-
If you entered everything correctly the panel on the right should populate with some folders and files. The left panel is showing your hard-disk files
How to find my theme files?
In the right panel find a public_html folder (or htdocs on Windows servers). Open that folder. If you installed WordPress in the root folder of your site you should see three folders called wp-admin, wp-content and wp-includes. All theme files are located in the wp-content folder; more specifically, the themes folder inside wp-content. A lot of times you’ll hear us say the term theme root. Theme root means you need to navigate to the first/parent folder of your theme. The path will be something like public_html/wp-content/themes/your_theme_name
How to install a theme?
Installing themes using FTP is really easy – drag-n-drop easy. Unpack* the theme (using software like 7-Zip) on your hard drive and navigate to it in the left (hard drive) panel. In the right (server) panel navigate to wp-content/themes. Now just drag your theme folder from the left to the themes folder on the right. When the files finish uploading go to your site Dashboard ⇨ Apparance ⇨ Themes and activate your theme.
– make sure you don’t extract the theme in a folder, use “Extract Here” so you don’t create a double folder problem.
For optimal viewing experience watch the video in Full Screen and HD quality
How to update a theme?
For detailed instructions on updating themes please read the following article. For video instructions on updating start watching the video tutorial above around the 4 minute mark.
How to overwrite a file?
To overwrite one of the theme files navigate to the folder where the file is located and just drag the file from your left (hard disk) panel to your right panel. When you do that you’ll be prompted to overwrite – click yes.
How to edit a file?
In case you want to edit one of the files navigate to it in your right (server) panel, right mouse click on the file and select View/Edit. When you do that the file will open in your default text editor. Edit the file in your text editor and when done hit Save. As soon as you hit Save a popup will appear in FileZilla asking you whether you want that file uploaded back to the server- be sure to click Yes.
How to change file/folder permissions?
In the right Filezilla panel (the server panel) right click on a file or folder and choose “File permissions…”. Inside the new window set the permissions either by clicking on the checkboxes or by entering the exact numerical value. Recommended permissions for files are 644, for folders 755. Some folders (like the cache folder) often require 777 permissions.
How can I find line no. 100 if there are no line numbers in Notepad?
If you plan on doing any serious file editing you’ll need to say goodbye to Notepad. My personal preference is Notepad++. The program is very easy to use, it features line numbers and also code highlighting.
How to make FileZilla open files in Notepad++
In case FileZilla doesn’t ask you which editor you want to use to edit php, js and css files go to (in Filezila) Edit ⇨ Settings… ⇨ File editing ⇨ Filetype associations and add Notepad++ as a default editor for your files. This is how that area looks in my FileZilla
If you followed this guide carefully you should now be able to (easily) navigate, edit and overwrite any file in your theme.