• Hi all,

    Not posted on here for sometime and recently updated my site from TwentyTwelve to TwentyFourteen.

    I am using a basic child theme and wanted to slightly tweak the “Proudly powered by WordPress” link at the bottom and also add a small dynamic copyright notice. I would ideally like to add this all to the child themes functions.php as like to keep my site upto date.

    So basically looking for something like below:

    Powered by WordPress
    © 2020 – Coder-Tronics

    I was playing around with this code but couldn’t get it to display anything yet

     * Change Footer Coipyright Message
     */
    add_action('wp_footer', 'footer_copyright');
    function footer_copyright() {
      echo '<div class="site-info"><p>This is inserted at the bottom</p></div>';
    
    }

    The page I need help with: [log in to see the link]

Viewing 4 replies - 1 through 4 (of 4 total)
  • Hi Antscran,
    You can try the plugin remove footer credit. It is easy and you don’t need any code.

    Good luck
    Etienne

    Thread Starter Antscran

    (@antscran)

    Hi Etienne,

    I would rather avoid plugins if possible, will keep researching the code and should figure it out eventually pending any further advice on here.

    Cheers,

    Ant

    your inserted stuff is there – just white-on-white in the white bar at the bottom.

    consider to use a different action hook, such as the one used in the footer.php of Twenty Fourteen:

    <?php do_action( 'twentyfourteen_credits' ); ?>

    and if you need to, hide the existing ‘Proudly powered by WordPress’ using CSS:

    .site-info .imprint { display: none; }

    Thread Starter Antscran

    (@antscran)

    Hi Michael,

    Thanks that gave me confidence some of my code worked atleast.

    I ended up reading a little more on child themes as been a awhile. Anyway settled on copy pasting the TwentyFourteen footer.php over to my child theme and making some minor edits and adding the following code snippet below which achieved what I wanted pretty much.

    		<div id="copy-right">
    		<p>&copy; <?php bloginfo('name'); ?> <?=date('Y');?>  - All Rights Reserved</p>
    		</div>
    • This reply was modified 5 years, 11 months ago by Antscran.
    • This reply was modified 5 years, 11 months ago by Antscran.
Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Editing the Footer using Functions.php’ is closed to new replies.