Retreiving anchor <a> value in JSP

Hi,

I think it's an odd question.We use request.getParameter(" ") to retreive the values of textboxes and submit button.How can I retreive the value of an anchor <a> tag?I want to retreive it's value and perform some operations based on it.Actually,I want my page to look like our forum page,where on the top,we have indexes(page numbers) as hyperlinks.These are generated dynamically.Please help.Thanks a lot. Sorry if my question is very odd.

[465 byte] By [ali_mohammeda] at [2007-11-27 5:07:10]
# 1
<a href=" http://example.com/servlet?foo=bar">click here</a>andString foo = request.getParameter("foo"); // barshould do.
BalusCa at 2007-7-12 10:26:10 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 2

Wow....

Thanks a loooot for that.It really works.It was super.How can I thank u?It really helped me.I got that foo is a user defined variable.I tried changine it.But what's bar?

Anyways,it really worked out for me.Can anyone tell me a substitute of goto in java?I think labels work in java.But how to call them? Actually,in my page,I want to recall if.

if( )

{

// check if button is clicked

}

for( )

{

// display records

}

// goto if and check if button is clicked

// if button is clicked,then display next set of records.

Plz don't get confused.In my previous message,I had given the complete code,but no authentic reply.I don't want to use while( ) as the system is getting stuck up ot the loop is going in an indefinite loop.

Please help.If there r any doubts,please ask me.

I shall b very thankful....

Anyways,BalusC,,,,Thanks a loooot for u r help.It really worked....

Thanks.....

ali_mohammeda at 2007-7-12 10:26:10 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 3

> Wow....

> Thanks a loooot for that.It really works.It was

> super.How can I thank u?It really helped me.I got

> that foo is a user defined variable.I tried changine

> it.But what's bar?

"bar" is the value of String foo.System.out.println(foo); // prints bar

> Anyways,it really worked out for me.Can anyone tell

> me a substitute of goto in java?I think labels

> work in java.But how to call them? Actually,in my

> page,I want to recall if.

Java doesn't know 'goto' as is in BASIC, VB or C. You may need while loops with boolean toggles, or labels and/or refractored methods. The requirement isn't clear to me. Under which condition should the if be recalled? Once you know it, use this condition in the while loop.

BalusCa at 2007-7-12 10:26:10 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...