• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

Can you set pages within a forum to no-index

cmeinck

Well-known member
#1
I'm aware of edits to make set meta on threads to no-index. This works well. Is it possible to do something similar for pages within a specific forum category node? For example, set pages within an Off Topic node to no-index. I could add to robots.txt, but that wouldn't remove existing pages that are indexed. Considering the individual threads are not indexed, it makes sense to do the same for the pages of threads.

Thanks!
 

Walter

Well-known member
#2
I'm not sure if I understood you right, but if you want to add a

<meta name="robots" content="noindex, follow" />

to a certain forum node (in addition to the thread itself) you can achieve this by editing the forum_view template and add
PHP:
<xen:if is="in_array({$forum.node_id}, array(1,2,3,4))">
  <xen:container var="$head.robots">
  <meta name="robots" content="noindex, follow" />
  </xen:container>
Replace 1,2,3,4 with the ids of the forums where you want the noindex.