• Resolved Revived

    (@revived)


    I tried pasting [oceanwp_date] in Footer Bottom and it’s not resolving. In other words, the shortcode is displayed as is.

Viewing 10 replies - 1 through 10 (of 10 total)
  • Theme Author oceanwp

    (@oceanwp)

    Hello, yes the shortcode is displayed like this in the customizer but it works in front end so you can use it.

    Thread Starter Revived

    (@revived)

    Then how would I add the year to the inner footer? Where do I paste the code?

    Theme Author oceanwp

    (@oceanwp)

    You can use this shortcode where you want. I use it in my footer bottom.

    Thread Starter Revived

    (@revived)

    I want to add it here:

    <div id="footer-bottom-inner" class="container clr">
      <div id="copyright" class="clr" role="contentinfo">
    YEAR

    I have NO idea where to add the shortcode to have it displayed there ^ When I look at footer.php, I don’t see those divs.

    Theme Author oceanwp

    (@oceanwp)

    You don’t need to edit any file, just go to the Footer Bottom section of the customizer and add your copyright with the shortcode in the textarea.

    Thread Starter Revived

    (@revived)

    That’s what I said I did (in the original post). Yet when I refresh the page, it shows the shortcode and not the year.

    Theme Author oceanwp

    (@oceanwp)

    Have you this issue in front end or only in bckend?
    In that case, yes you can edit the copyright.php file into your child theme, just copy this file from oceanwp/partials/footer/ in the same path into your child theme, open it in your text editor and replace this code:

    <?php echo wp_kses_post( do_shortcode( $copy ) ); ?>

    by your text and for the shortcode, you need to add it like this:

    <?php echo do_shortcode( '[oceanwp_date]' ); ?>

    So for example:

    Copyright <?php echo do_shortcode( '[oceanwp_date]' ); ?>, all right reserved.
    Thread Starter Revived

    (@revived)

    I now see copyright.php.

    So when I copy that file to my child theme, do I have to keep the directory structure intact?

    In this case, /partials/footer/

    Or do I place copyright.php in the same folder as functions.php & style.css?

    Theme Author oceanwp

    (@oceanwp)

    Yes you need to paste this file in your child theme in the same path, so partials/footer.

    Thread Starter Revived

    (@revived)

    👍🏼

Viewing 10 replies - 1 through 10 (of 10 total)

The topic ‘[oceanwp_date] shortcode doesn’t work in Footer Bottom’ is closed to new replies.