Can I pate code into the functions.php file within my theme with wordpress.com?
-
Can I pate code into the functions.php file within my theme with wordpress.com? Can I do it without SFTP?
The blog I need help with is: (visible only to logged in users)
-
Sorry, it should read: Can I paste code into the functions.php file within my theme with wordpress.com? Can I do it without SFTP?
-
Hi there,
functions.phpcannot be directly edited on most WordPress.com themes, even with access to sFTP. Please check out our support page for more information:This feature is available on sites with the WordPress.com Business or Ecommerce plan. If your site has one of our legacy plans, it is available on the Pro plan. This guide will show you how to use SFTP on WordPress.com. Before BeginningWhat is SFTP?Getting Started with SFTPSetting up a ClientFileZillaTransmit (macOS)Cyberduck (macOS and Windows)Forgotten PasswordWhat if something goes wroHowever, if you want to add custom code to the
functions.phpfile of your WordPress.com site, you can use the Code Snippets plugin, which allows you to add custom code snippets to your site without directly modifying the theme files. Here are the steps to add code using Code Snippets:- Install and activate the Code Snippets plugin on your WordPress.com site.
- Once activated, go to the “Snippets” option in your WordPress dashboard menu and click “Add New”.
- Give your snippet a name and paste the code into the “Code” box.
- Choose “Functions” as the snippet type and “Save Changes and Activate” to add the code to your site.
It’s important to note that adding custom code to your site can be risky, as it can potentially break your site or cause security vulnerabilities. So, it’s always a good idea to back up your site before making any changes.
A plugin-enabled Plan is required to install plugins on your WordPress.com site. The Business Plan is a great option – in addition to plugin support and sFTP access, you also receive 200 GB of media library storage, real-time backups, live chat support, and more:
I hope this helps! If you have any further questions, feel free to ask.
-
Thanks.
I will have a business plan.
Relating to the use of the Code Snippets plugin, it is the best option. However, this plugin, in the past, gave me some compatibility problems with other plugin (I don´t remember the name).
-
Good to know! I imagine it could be tricky to troubleshoot, since it could be the plugin itself, or it could be the code you’re adding with it, but if you see this issue again we can help you troubleshoot.
Let us know how we can help!
- The topic ‘Can I pate code into the functions.php file within my theme with wordpress.com?’ is closed to new replies.
