Page problem or config file?
I've designed a page in JSP whereby it acts as a search engine that allows searching of keywords on selected online databases / search engines like Google, EIU, etc.
The problem is that for those search engines that employ the GET method (not POST), the search results are not shown on the page. I've traced the logs and the search results are apparently in the logs. Each search engine has its own configuration file in XML format.
Is it got to do with my page or is there a part in the XML file that needs a change of syntax? Here's the config file for the reference.
<?xml version="1.0" encoding="ISO-8859-1"?>
<esam>
<host address="google" />
<assign var="$rms$" template="Google" regexp="(.*)" parenthesis="1" subgroup="1" />
<assign var="$url$" template="http://www.google.com.my" regexp="(.*)" parenthesis="1" subgroup="1" />
<encode var="$searchwhat$"/>
<getfile method="GET" path="/search?hl=en&q=$searchwhat$&btnG=Search&am p;meta=" >
<header name="User-Agent" value="Mozilla/4.0 (compatible; MSIE 5.01; Windows NT)" />
<getvar var="$desc$" regexp="<p class=1><a href=(/[\^$]*/) onmousedown="([^"]*)">(.*?)</a>" parenthesis="3" subgroup="1" />
<getvar var="$href$" regexp="<p class=1><a href=(/[\^$]*/) onmousedown="([^"]*)">(.*?)</a>" parenthesis="1" subgroup="1" />
<getvar var="$total$" regexp="<font size=-1 color=>Results <b>([0-9]*)</b> - <b>([0-9]*)</b> of about <b>([^<]*)</b>" parenthesis="3" subgroup="3" />
<getvar var="$tmpnext$" regexp="<a href=([^>]*)><img src=/nav_next.gif width=100 height=26 alt="" border=0><br><span class=b>(.*?)</span>" parenthesis="2" subgroup="1" />
</getfile>
<assign var="$next$" template="$url$$tmpnext$" regexp="(.*)" parenthesis="1" subgroup="1" />
</esam>
Please help. Thank you.
|