hyperlink id's

himy scenario is like thisi hav a list of items as hyperlinks . and when i click those hyperlinks the name of the item must be passed to a common search page...how can i do thatthanks
[204 byte] By [amrishkra] at [2007-11-27 5:21:20]
# 1
Pass it as query parameter?
BalusCa at 2007-7-12 11:46:20 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 2

but the value of the variable keeps on changing......let me make it clearer

my site is as follows

the following r latest uploaded files:

1.a

2.b

3.c

4.d

all r hyperlinks

these items r fetched from database and printed using n array. now if a user clicks on any item it shud be sent to a search page so that it can be searched.

thanks

amrishkra at 2007-7-12 11:46:20 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 3
Pass it as query parameter.
BalusCa at 2007-7-12 11:46:20 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 4
it wont work....because i m printing the list using an array...and if i pass it using query parameter every time the last element of the array will be passed....but i want any element to be passed
amrishkra at 2007-7-12 11:46:20 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 5
can u help?
amrishkra at 2007-7-12 11:46:20 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 6
You said that it won't work, then so be it.But the solution is certainly to pass it as query parameter, so that you can identify the item on the server.
BalusCa at 2007-7-12 11:46:20 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 7
can you plz tell me how?....mayb code sample
amrishkra at 2007-7-12 11:46:20 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 8
http://example.com/servlet?foo=barwhich can be retrieved as followsString foo = request.getParameter("foo"); // bar
BalusCa at 2007-7-12 11:46:20 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 9
got it....thanks
amrishkra at 2007-7-12 11:46:20 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...