Solution to update wordpress footer copyright text via child theme using Independent Publisher
Well I got the solution how to implement. It’s quite easy actually that I never thought of doing it. So here it goes with the steps if someone else is looking for the solution.
Step1
Create a functions.php inside your child theme where you have your style.css file is located.
IMPORTANT: functions.php is very delicate, so be careful what to put and what not to. You might see a white screen of death and your admin page won’t work. It means something went wrong with the functions.php file. Just use any FTP client and navigate to your Independent Publisher Child folder. Now move that functions.php file to your desktop and refresh the wordpress/ftp etc. You can now access your wordpress site as before. Now crosscheck what went wrong with the codes, make the changes and put it back under the same location. Hit refresh and test.
Step2
Copy the following functions (or you can use the entire file as mentioned here)
function independent_publisher_footer_credits() {
$my_custom_footer = 'This is my custom footer.';
return $my_custom_footer;
}
Make sure you add this php opening tag <?php
before anything else.
Remove any extra WHITE/BLACK space after the code. Save the functions.php file.
Step3
Refresh your WordPress Dashboard or clear all cache (for W3 Total Cache users) and view your site as Admin. Just scroll down to the end of the footer. You will see this text This is my custom footer.
This shows your child theme footer codes are working fine. If you still seeing the default footer text, just make sure you have removed the comments from the code (it happens if you have copied these codes from the source link)
Step 4
For updating the footer content, open your functions.php (that you have created in Step 2) and replace the following text
This is my custom footer.
without the single quotes with your own html markups. Save the file, hit refresh/clear all cache (for W3 Total Cache) and test. It should be updated!
Your final edited code would look like the following example when you replace this only text This is my custom footer. from the code.
<?php
/*
* Modifies the default theme footer.
* This also applies the changes to JetPack's Infinite Scroll footer, if you're using that module.
*/
function independent_publisher_footer_credits() {
$my_custom_footer = '<span style="color: #808080;">Powered by WordPress. Copyright 2014.</span>';
return $my_custom_footer;
}
That’s it.