Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Is it possible to create a second search box / block, and have it only search within / below a certain path on the site? For instance rather than www.example.com have it search within content at and under the path of www.example.com/test ?
Would it need to be another module, or could the form / results be modified with some PHP in a block?
Comments
Comment #2
iamEAP CreditAttribution: iamEAP commentedHey @Pepper,
This is a use-case I've been toying with in a separate project called Google Search Collections. I don't remember if it's implemented at the block-level yet, but it's certainly on the road map. For now, it's possible via tabs.
That module's still in development, but might be a nice place to start. Otherwise, it would be possible, but would require a significant amount of development work.
Comment #3
Pepper CreditAttribution: Pepper commentedThanks iamEAP. I'll check that out.
Comment #4
iamEAP CreditAttribution: iamEAP commentedNo problem. Although old, this article also has a lot of info on doing alters in code to do what you're trying to do.
Closing this out for now, but feel free to re-open or open another.
Comment #5
Pepper CreditAttribution: Pepper commentedI'm having some major problems trying to install your dev module / get it working with the google search appliance. Were you just suggesting I look at the code for examples rather than actually try to install, as it's not in an install_ok state?