Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
+1 vote
376 views
in Q2A Core by
I want to noindex a question with less content

Example, I have a question with 2 answer.

If total word in these answers < 300 word, q2a will automatic "noindex" this page.

But then these answers >300 word (or somebody add more answer and total word in answers >300 word) , q2a will automatic "index" this page.

Please help me

1 Answer

0 votes
by

You would need to create a layer plugin to override one of the head functions (head_meta() I think).

Then in the function check the questions and answers length (the content should be in the $this->content variable) and if it meets your criteria, output the HTML:

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

 

by
I dont know create a plugin.  Please help me
by
@Scott Please help me, $this->content[ 'what' ]

I dont know, please help me this var, i dont know which var can i use.
...