Adding New Files To A Theme (Using Only Theme Editor)

To add a new file to theme using only theme editor, add this to “Header.php”:

touch('wp-content/themes/your_theme_directory/your_new_file_name.php');

then visit your sites home page and the file will be created!

Remember to delete it immediately after adding it!

I used:

touch('wp-content/themes/Beans-master/lib/admin/assets/js/numscroller-1.0.js');

To add “numscroller-1.0.js” to my website (more on that later if I can make it work).

Filed under: WordPressTagged with: ,

No comment yet, add your voice below!


Add a Comment

Your email address will not be published. Required fields are marked *

Comment *
Name *
Email *
Website