- This topic has 6 replies, 2 voices, and was last updated 3 years, 4 months ago by
David.
-
AuthorPosts
-
November 25, 2022 at 10:11 am #2433755
Philippe
Hi,
I need to use <META NAME=”ROBOTS” CONTENT=”NOARCHIVE”> for some specific posts behind a metered paying wall. The intent is to prevent people from accessing these posts through a cached Google link.
I know the tag is supposed to go in the “head” of the concerned posts. Here are my questions:
1/ How to access this darn “head”?
2/ Is it enough to just put there <META NAME=”ROBOTS” CONTENT=”NOARCHIVE”> and nothing else?
3/ The concerned posts belong to specific categories. Can the manipulation be done at the category level?Isn’t that nice to speak with an eternal newbie? 🙂
Thanks for your help,
Philippe
November 25, 2022 at 10:26 am #2433854Philippe
I think I am almost there.
I added a new hook in wp_head with <script> META NAME=”ROBOTS” CONTENT=”NOARCHIVE” </script> and set the display rule location according to the concerned posts’ Categories.
Is the script ok?
Do I need to select the post category archive as well as a location in Display Rules?
November 25, 2022 at 10:35 am #2433914David
StaffCustomer SupportHi there,
1. Create a new Hook element.
2. Add your meta tag:<META NAME="ROBOTS" CONTENT="NOARCHIVE">
NOTE: Do not add the<script>tags.
3. Set the Hook towp_head
4. Set your Display Rules for the pages or posts that you require it.HINTS:
Post Category -> Term = a Single Post of as specific category.
Post Category Archive > Term = an Archive page showing posts of a specific category.November 28, 2022 at 3:23 am #2438599Philippe
Hi,
I do not get that:
Post Category -> Term = a Single Post of as specific category.
Post Category Archive > Term = an Archive page showing posts of a specific category.What do you mean? That if I create a hook for a post category or a post archive category it will not be applied to each post individually in these categories?
Thanks for your help,
Philippe
November 28, 2022 at 6:39 am #2438866David
StaffCustomer SupportOk, lets say i have 10 posts that are all in the Category of:
CheeseIf i set the display rules to:
Post Category -> Cheese.Then the
noarchivemeta will be added to ALL 10 posts.Now i also have
mysite.com/category/cheesewhich is the archive page displaying my posts about cheese.
If want add thenoarchivemeta to just the archive page then i use:Post Category Archive -> CheeseIf i want to add the
noarchivemeta to my Single Posts and my Archive then i would add both of those display rules.November 28, 2022 at 7:03 am #2438911Philippe
Got it. It’s the word “single” that was confusing me.
Thank you.
November 28, 2022 at 7:29 am #2438967David
StaffCustomer SupportAah yes, sorry i should have made that clearer 🙂
Glad to be of help!
-
AuthorPosts
- You must be logged in to reply to this topic.