Home Forums Weaver Xtreme Theme Copyright Code

Topic Resolution: Answered
Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #66297
    Answered
    babcockam
    Participant

    At one point I had a code placed in the Site Copyright that updated the year, and it is no longer displaying correctly.

    It has errored on over 30 websites. This is the code I have in place:

    © Copyright <script>document.write(new Date().getFullYear());</script> Lintz Land Design. All Rights Reserved.

    And this is how it is now displaying:

    © Copyright document.write(new Date().getFullYear()); Lintz Land Design. All Rights Reserved.

    Thank you!

    Home

    #66303
    scrambler
    Moderator

    I tried on my test site and had the same problem.

    so @weaver will have to check, it seems the script tags are being ignored in the copyright box…

     

    #66307
    Weaver
    Keymaster

    WordPress has increased the security standards, and that sort of script in a text field is no longer allowed. I really can’t do anything about that.

    There is an automated check when a theme is uploaded, and that gets caught if the contents of a text box is not filtered. You can’t enter <script> in a post, either, for example.

    #66308
    scrambler
    Moderator

    Good to know.

    @babockam, you may be able to use a php shortcode to do the same, I will try it

    #66309
    Best Answer
    scrambler
    Moderator

    This reply has been accepted as the best answer.

    It works.

    If you have plus, activate the PHP shortcode in the Plus options > PHP page

    then add the following to your footer box

    © Copyright [php]echo date(“Y”);[/php]Lintz Land Design. All Rights Reserved.

    #66341
    babcockam
    Participant

    Perfect! Thank you so much for the help!

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.