I think you should pass the ID as parameter but use NSummary to display
the list, like this:
out.print("<a
href="+req.getContextPath()+"/servlet/Detail?id="+id+"&otherparameter="+otherparameter+">");
out.print(NSummary);
out.print("</a>");
I hope this will help.
Bob Prah wrote:
> Hi All,
>
> I have a servlet that makes a connection to a table say NewsTable in a
> mysql database News.
> Table NewsTable has the ff. columns Id, Nsummary and Detail. I am
> able to access table
> NewsTable and display the contents in the various columns namely Id,
> Nsummary and Detail in a
> servlet.
>
> My objective is to display each item in column Nsummary in a hyperlink
> format so that when it is clicked upon, its corresponding Detail
> content will be displayed. Id is the index and unique.
>
> I have been able to transformed each content of Nsummary into a
> hyperlink on display in my
> servlet, however when I click on the link, it leads me to the index
> page my web. appl.
>
> I suppose I am doing something terribly wrong. getting this result. I
> used a code segment
> like this :
>
>
> for (int i=1; i <= Nsummary.length; i++){
>
> out.println("<tr><td width =\"300\"><div><p><a href=\" " +
> Detail[i] + "\">" +
> Nsummary[i] +
> "</a></p><p></p></div></td></tr>");
>
> }
>
> I Would appreciate any suggestion that anyone has to the above. Thank
> you.
>
> p.s. : sorry, my previous problem description was not clear enough
>
___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".
Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html