In 2k11, I use a "non-plugin" search form hardcoded into the template to make up for the non-HTML5 markup emitted by the quicksearch plugin. However, this will not "adapt" functionality added by plugins to the quicksearch sidebar plugin like i.e. livesearch.
Is there a way to add i.e. livesearch functionality to hardcoded search forms? Some kind of hook I can use?
YL
Adding livesearch functionality to non-plugin search form
-
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Re: Adding livesearch functionality to non-plugin search for
Hi!
The generate_content() of the quicksearch plugin uses the eventhook "quicksearch_plugin", so you should be able to hook that in smarty as well (probably using hookAll=true).
Note though that the livesearch plugin (which is the only plugin using that hook) emits code that relies on the input search field having the DOM ID "#serendipityQuickSearchTermField" and the <form> tag surround it needs to be called "#searchform".
HTH,
Garvin
The generate_content() of the quicksearch plugin uses the eventhook "quicksearch_plugin", so you should be able to hook that in smarty as well (probably using hookAll=true).
Note though that the livesearch plugin (which is the only plugin using that hook) emits code that relies on the input search field having the DOM ID "#serendipityQuickSearchTermField" and the <form> tag surround it needs to be called "#searchform".
HTH,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
Re: Adding livesearch functionality to non-plugin search for
Hm, I have:garvinhicking wrote:The generate_content() of the quicksearch plugin uses the eventhook "quicksearch_plugin", so you should be able to hook that in smarty as well (probably using hookAll=true).
Code: Select all
{serendipity_hookPlugin hook="quicksearch_plugin" hookAll="true"}
YL
-
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Re: Adding livesearch functionality to non-plugin search for
Hi!
Yes, if the IDs do not match it will definitely not work.
Regards,
Garvin
Yes, if the IDs do not match it will definitely not work.
Regards,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/