We implemented Google Custom Search on our site, however it will often return pages that have "Searchable" set to "No", and "Show in menu: No" -- so why does Google still see the pages?
For example, I’d like to prevent CSE from seeing XML files that MODX creates.
Does anyone know how to do this, without manually typing in every page into a robots.txt file?
IIRC, those checkboxes in the Manager are for MODx scripts, like AjaxSearch. I don’t think it affects stuff like Google’s search.
When you mark a page as "NOT searchable" - a Robots meta tag
with "noindex, nofollow" is inserted to keep web search engines
from indexing that document.
More --->
http://modxcms.com/MetaTagsExtra-930.html
It turned out some of the pages had "Show in menu: Yes", I can’t switch them off because they are used in ditto calls.
I’m going to use the meta tags and robots.txt
The other alternative I’m using is to filter out any reference to *xml in the CSE and filter out any filetype:xml in the CSE.
Thanks
Sorry, quick question. Wouldn’t putting Meta tags like a robots meta tag inside an XML file prevent it from being a validate XML file?
Yes you are right MetaTagsExtra snippet will not help you.
-
☆ A M B ☆
- 2,475 Posts
Hmm... you may want to use the rel="nofollow" attribute in your page’s "Link Attributes" field. I haven’t tried this, but in theory, the "nofollow" attribute means that a search engine should ignore that page... MODx’s "Link Attributes" field is just an easy place to put that value. It wouldn’t hurt to try, unless you want the "regular" Google to search and index those pages.