I already know how to add noindex nofollow to individual pages and posts by using the "Publish" Custom Field. I don't know how to ad noindex nofollow to categories since Wordpress doesn't have custome fields for categories. Doesn't anyone know how to deal with this?
I would edit the theme files and use conditional tags to print the appropriate meta code when certain categories are displayed.
Not so familiar with those, but basically what you are saying is use something along the lines of <?php if ( is_category() ) <meta name="robots" content="noindex, nofollow"> endif; ?> Code (markup): Also I'm thinking it might also be easier to simply post the whole <meta name="robots" content="noindex, nofollow"> into the categories template page header so that whenever a category page is created the meta will be in the header. I'm not quite sure if its a bad idea.
Exactly. But if you want to affect all categories (not just specific ones) I would just do it via robots.txt ("Disallow: /category/" or something like that). It's an easier solution.
I actually did that already, but since they there are links in the actual theme to the categories they say it will still be indexed so the best way was to noindex nofollow the pages. Yes I want to affect all the categories because I'm creating my own pages for the categories so they category pages would be redundant to google search. Thank you so much for you help so far. So it is a no-go for straight-forward paste it in the category template?
Well, you might want to add it there if you want to but I think it's redundant. The purpose of robots.txt is to let crawlers know that you don't want them to access (index) specific pages. (By the way, there should be a tool in Google Webmaster Tools which can tell you whether specific URLs are accessible to Google.)
Did you mean you want to create a category page with a page template? If yes, then add this to header.php <?php if ( is_page_template( 'category-page.php' ) ) <meta name="robots" content="noindex, nofollow"> endif; ?> PHP: category-page.php if your actual category template name with correct path
Funny enough I've done that as well, but can't really figure out which ones are inaccessible. I think I just need time to let google crawl my site. I already have a category page template that comes with the theme I'm using. Since the code you gave me pretty much means the meta noindex,nofollow code materializes in the header whenever its a category page wouldn't it be much simpler if I just paste the meta code into the header of the category page template (category.php) so php wouldn't need to process it?
Of course you can just paste the meta tags in your category.php. But I wouldn't recommend this. In most cases these kind of meta tags are better within the head.
Sorry to nitpick, but wouldn't it be technically be the same if I paste the meta tage in the header section of the category.php since the php is technically made to put it there whenever the template is category.php. Again I'm not sure because I'm pretty new to this.