Including static pages in the search index? I've got a page set up like this:

$items['mypage'] = array(
  'title' =&gt; 'My Page',
  'page callback' =&gt; 'mymodule_mypage',
  'access callback' =&gt; TRUE,
);


and then

function mymodule_mypage() {
    return 'This is a test! Also, pollywog.';
}


Now, if I go to /search/node/pollywog, I would like to see the above page as one of the search results. I currently don't, because I assume search just covers database content. Is there a way to make it also include specific pages? Something like the below would be amazing:

$items['mypage'] = array(
  'title' =&gt; 'My Page',
  'page callback' =&gt; 'mymodule_mypage',
  'access callback' =&gt; TRUE,
  'includeInSearchIndex' =&gt; TRUE, // &lt;&lt;----- this!!
);


Would it be possible to build in something like "includeInSearchIndex" and then make that index the static page?
Your module needs to implement hook_search_info, hook_update_search and as part of that hook call search_index and then fully define how the content is indexed.

Out of interest why don't you just create static pages as regular nodes?