You could create a view that shows all the nodes, filtered to the node type you want. Then add the filter Search:Index, and expose it. The user will see all nodes of that type, and be able to search through them. This is all without you doing any sort of coding.
Thanks for the tip. I need a search box on the front page though -- it should say "search for businesses", and be limited to the content type called "business".
You could use the same idea in the last comment. Create a view, with the filter node:type and then select businesses, set the header of the block to "Search for businesses", and include a search:index exposed filter.
I experimented with that, but I'm not sure how to prevent it from listing the nodes.
Is there a way to have a simple search box that when you enter a search query it takes the user to the search results page? It shouldn't list the results on the front page.
After you install it go to the search settings and there will be an advanced drop down at the bottom of the page, you can then limit the search results by content type.
Comments
You could create a view
You could create a view that shows all the nodes, filtered to the node type you want. Then add the filter Search:Index, and expose it. The user will see all nodes of that type, and be able to search through them. This is all without you doing any sort of coding.
-cwgordon7
Thanks for the tip. I need
Thanks for the tip. I need a search box on the front page though -- it should say "search for businesses", and be limited to the content type called "business".
--
http://drupalzilla.com/ — Drupal SEO
You could provide a block
You could use the same idea in the last comment. Create a view, with the filter node:type and then select businesses, set the header of the block to "Search for businesses", and include a search:index exposed filter.
search box
I experimented with that, but I'm not sure how to prevent it from listing the nodes.
Is there a way to have a simple search box that when you enter a search query it takes the user to the search results page? It shouldn't list the results on the front page.
(example.com/search/)
hook_form_alter
You can do it with hook_form_alter. See my comment under the search block snippet:
http://drupal.org/node/141788#comment-730057
--
https://www.codeenigma.com/
This sounds like what I'm looking for
I'm was trying to do what you suggested as it sounds like exactly what I'm looking for, but search:index isn't in my filter types. any ideas?
Screen of options - http://twitpic.com/1pnqd
Check out search config
There is a module that might work for you: http://drupal.org/project/search_config
After you install it go to the search settings and there will be an advanced drop down at the bottom of the page, you can then limit the search results by content type.