Using %currentyear% in Post Title

#227157
  • Resolved Abdul Rahim
    Rank Math pro

    While using %currentyear% in Post Title, for certain posts in the Google SERPs it is showing as %currentyear% instead of 2021. This is happening only for certain posts.

    Is there any way to avoid this in the SERPs

Viewing 10 replies - 1 through 10 (of 10 total)
  • Prabhat
    Rank Math agency

    Hello,

    Thank you for contacting us and we regret the inconvenience caused.

    Could you confirm if the variable is added in the SEO title field? If yes, then we checked the post’s source and we were able to replicate the issue. You can have a look at the screencast in the sensitive data section of this ticket.

    Please remove the %currentyear% from the SEO title of the post and then again add it and update the post. Further, please follow the screencast in the sensitive data section to check the source of the post to see if the SEO title is updated.

    In the source of the post, you should see 2021 in place of %currentyear% in the <title> tag.

    Please let us know how that goes.

    Thank you.

    Tried removing and updating it as advised but still not able to see 2021.
    I moved the post to draft and updated it, still it didn’t work.

    Prabhat
    Rank Math agency

    Hello,

    We might need to take a closer look at the settings. Please edit the first post on this ticket and include your WordPress & FTP logins in the designated Sensitive Data section.

    Please do take a complete backup of your website before sharing the information with us.
    Sensitive Data Section

    It is completely secure and only our support staff has access to that section. If you want, you can use the below plugin to generate a temporary login URL to your website and share that with us instead:

    https://wordpress.org/plugins/temporary-login-without-password/

    You can use the above plugin in conjunction with the WP Security Audit Log to monitor what changes our staff might make on your website (if any):

    https://wordpress.org/plugins/wp-security-audit-log/

    We really look forward to helping you.

    Hello,

    I have updated the sensitive data as requested. Can you please check further?

    Thank you.

    Prabhat
    Rank Math agency

    Hello,

    I visited your website’s admin area and upon checking the post, I found that you’ve placed the %currentyear% variable in the post title rather than the post SEO title.

    Adding the variables in the post title and then simply using the post title in the SEO title would make the entire post title a text, rather than a variable. Hence it would be displayed as it is i.e, the name of the variable.

    Also, if you would check the SEO title preview in the snippet editor, it would show you the variable name instead of the value (i.e, 2021).

    Please have a look at the screencast in the sensitive data section of this ticket and modify the post and SEO title by removing the variable from the post title and adding it in the SEO title to fix the issue.

    Hope that helps.

    Thank you.

    Hello,

    I have updated the sensitive data as requested. Can you please check further?

    Thank you.

    Ankit
    Rank Math business

    Hello,

    The title seems to be appearing on your web page. Please have a look I have shared the screenshot inside sensitive data section.

    Looking forward to helping you. Thank you.

    Prabhat
    Rank Math agency

    Hello,

    Adding to my colleague’s reply, the variables of Rank Math are to be used inside the fields of Rank Math only.

    Though the %currentyear% variable was working on your end by placing it in the post title, issues were clearly visible, since the SEO title took the variable as text.

    Also, adding the year on both places (i.e, post title & SEO title) and then using the post title as it is in the SEO title, would result in the SEO title having the year twice (ex. post-title 2021 - 2021).

    In most cases, since Google shows the SEO title in the search results, I suggest you place the current year in the SEO title only.

    However, if you wish to include the year in both places, then you’ll have to either set a different format for the SEO title or use a custom SEO title.

    Hope that helps.

    Thank you.

    Thanks for the support. I will use it as advised

    Prabhat
    Rank Math agency

    Hello,

    We’re glad that we could address your concern.

    If you have another question in the future, please feel free to reach out, and it will be our pleasure to assist you again.

    Thank you.

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

The ticket ‘Using %currentyear% in Post Title’ is closed to new replies.