[InterMine Dev] Custom search tools

Alex Kalderimis alex at intermine.org
Wed Nov 21 16:59:39 GMT 2012



On 21/11/12 16:51, Thomas TRIPLET wrote:
> Hello,
> I looked a bit more closely at the issue and have a few questions. In
> quickSearch.jsp,

The way struts works is that that jsp will be managed by a controller
(in this case org.intermine.web.struts.KeywordSearchResultsController).
The flow of control is rather opaque and need a bit of knowledge of
struts and a thorough reading of the file struts.xml and tiles.xml.
Rather than hacking the controller, we suggest you use a javascript file
to intercept the input to this box and send it to your preferred
destination instead. New javascript files can be added by listing their
location in your .properties file (eg
"head.js.all.QUICK_SEARCH_INTERCEPT = my-quick-search.js). You will need
to bind to the box manually. We can help you with that if you like.

the form is redirected to /keywordSearchResults.do/.
> The only file I could find with a related name
> is /keywordSearchResults.jsp/, but from the code, I  looks like this is
> to display the results, not producing them. So I'm a bit confused. Where
> does the request to /keywordSearchResults.do/ go and where is the real
> work done (i.e. querying the db)? And how does it send the output
> to /keywordSearchResults.jsp/ to display the results?
> Thanks a lot for your input
> Thomas
> 
> --
> Thomas Triplet, Jr. Eng., Ph.D.
> http://www.thomastriplet.net
> 
> 
> On Wed, Nov 21, 2012 at 10:50 AM, Thomas TRIPLET
> <thomastriplet at gmail.com <mailto:thomastriplet at gmail.com>> wrote:
> 
>     This is great! I was also wondering whether there is a standard way
>     to add a tab at the top to offer an advanced search page (next to or
>     in replacement of the querybuilder), or will I need to hack the
>     backbone?
>     Thanks,
>     Thomas
> 
>     --
>     Thomas Triplet, Jr. Eng., Ph.D.
>     http://www.thomastriplet.net
> 
> 
>     On Wed, Nov 21, 2012 at 4:35 AM, Radek Stepan <rs676 at cam.ac.uk
>     <mailto:rs676 at cam.ac.uk>> wrote:
> 
>         Hello,
> 
>         you can edit the two JavaScript functions in
>         intermine/webapp/main/resources/webapp/quickSearch.jsp to
>         redirect to
>         a page of your choice passing the value of the input as a parameter.
>         This means you do not need to touch the InterMine Java backend
>         at all.
> 
>         Radek
> 
>         On Tue, Nov 20, 2012 at 10:56 PM, Thomas TRIPLET
>         <thomastriplet at gmail.com <mailto:thomastriplet at gmail.com>> wrote:
>         > Hello,
>         > I was wondering how easy it would be to implement custom
>         search functions to
>         > extend the quick search. I am thinking in particular of BLAST,
>         and in-house
>         > semantic mining tools. The idea would be to redirect the
>         search button to
>         > another server, which then returns the output to my instance
>         of intermine
>         > and displays the results as a standard intermine table.
>         > Thanks,
>         > Thomas
>         >
>         > --
>         > Thomas Triplet, Jr. Eng., Ph.D.
>         > http://www.thomastriplet.net
>         >
>         > _______________________________________________
>         > dev mailing list
>         > dev at intermine.org <mailto:dev at intermine.org>
>         > http://mail.intermine.org/cgi-bin/mailman/listinfo/dev
>         >
> 
> 
> 
> 
> 
> _______________________________________________
> dev mailing list
> dev at intermine.org
> http://mail.intermine.org/cgi-bin/mailman/listinfo/dev
> 



More information about the dev mailing list