In many tutorials, for various customizations of his WordPress website is indicated to insert a certain code in the file „functions.php“. But how do you actually do that?
How do I find and edit the „functions.php“ file?
There are several possibilities:
Option 1: In the WordPress backend
Log in to your WordPress backend as administrator.In the menu item „Design“ you will find the sub-item „Theme file editor“. In the right column, select the file „Theme functions“ (functions.php) and you can insert the code in the editor.
The only problem: You save something in this file of a theme. If the manufacturer of the theme offers an update, in which also this file is updated, then your inserted code in this file is lost.
Daher: Mach deine Änderungen in einem ein Child-Theme!
Option 2: Via FTP
If you don’t have permissions in the wordpress backend, you can also download the file via FTP, edit it and upload it again.
How to do that?
With a FTP client like FileZilla or CyberDuck you can connect to the FTP access data of your hoster. There you will see all files of your WordPress installation. In the folder /wp-content/themes/ you will find the installed themes. Open the folder with the name of your theme and there you will find the file functions.php. You can now download this file, edit it in a code editor of your choice – just add the code mentioned above to the bottom of the file – and then upload it again.
Option 3: With a code-embed plugin
I am not a friend of unnecessary additional plugins, so I mention this way only at the end. But if you didn’t manage to use the two ways above, you can easily install a plugin like My Custom Functions to insert the code.