default userpic

Implicitly calling MT Search function from outside MT

Vote 0 Votes

I have a web application (J2EE). From one of its page I want to call the MT Search function with the search keywords such that thereafter MT search function internally searches for those keywords and loads the MT Search results page if any blog entries match the criteria else the MT home page is loaded.

Please let me know if this is possible and please on any pointers to the documentation on this.

Reported on Movable Type 4.2

3 Replies

| Add a Reply
  • I would use java.net.HttpUrlConnection to read the page from a servlet, do a regular expression search for search results markup, and then have the J2EE container do a forward to the main page. If you search for the CSS class information for a search result, that should be more than enough to verify results.

    • default userpic

      Thanks Mike, My query is that "Is it possible to call the Search Function of MT through an API from an outside application". Your answer seems to suggest that it is possible. Wanted to confirm in any case. Any pointer in MT documentation on how to call Search API of MT will also be helpful.

      • Not really. Perl has no hooks into the JVM and vice versa. You're going to have to rely on good old Java HTTP APIs for this. Just look around the net for good Java examples of downloading a web page with HttpUrlConnection.

Add a Reply

Forum Groups

151 405

Last Topic: MT Interface Missing by Sherri on Nov 10, 2008

36 144

Last Topic: Installation can't finish by Drazend on Nov 10, 2008

34 93

Last Topic: Creating your own Plug-in by jondauz on Nov 5, 2008

10 33

Last Topic: new licensing confusion by Neil Epstein on Aug 14, 2008

code.sixapart.com

62 226

Last Topic: Callback after blog publishing. by Tomato Interactive on Oct 27, 2008

34 98

Last Topic: Ajax Rating Plugin by kiran on Oct 17, 2008