How to add the a code inside head tags


Hi,

I need to add the following code the below code inside head tag

<?php if
  (
 is_search() ||
  is_archive() ||
 is_404() ||
 is_feed() ||
  is_paged()
  ){ ?>
 <meta name="robots" content="noindex,follow" />
<?php } ?>

I searched for head tag in the master code but could not find it, can you please let me know how to do this?

Thanks, Venkatesh


Hi Venkatesh,

See this answer in which I posted a code snippet which you can use to add your other meta too.

Let me know if you are facing difficulties 😉

Write a reply

Login or register to write a reply, it's free!