Hi,
I didn't understand all of ur question. but i got the impression
that u simply don't want to display the vendor number in the
address bar.
i might be wrong, do correct me if i am, but here's my
suggestion:
i think u could do put the links within a form with a hidden field
called vendornumber. using javascript and onClick, set the value
of this field and then do a form.submit(). Let the actual HREF
value be some dummy "#" or something.
From what i figured, u'r trying to set the value of a server-side
bean using client-side javascript. I don't think this is possible.
If it is, pls tell me how.
You *could* do it differently, with more effort, which i find
unnecessary: u could use javascript to open a
vendornumber.jsp?number=01234 file in a different frame. Then
you'll have to use some kind of checks on the server side to see
whether the value of the bean has been set, and to proceed only if
it has.
I didn't understand what u said about xml-style and pure java.
cheers
-erwin
On Sat, 09 Mar 2002 Rick Snide wrote :
>I have a page "vendors.jsp" where (using a bean) I display a list
>of vendors to choose from. This list of vendors is a list of
>hyperlinks that the user can click. I want the user to click the
>link and then see the parts that are associated with that vendor
>(vendorparts.jsp). My thought was to use the
>HREF=vendorparts.jsp and also use the onclick method to set the
>vendor number selected in the bean for the vendorparts.jsp to
>know whose parts to display.
>
>my list of links (created by my bean) has items like this for the
>user to choose:
><A HREF=vendorparts.jsp
>ONCLICK="submit_onclick('0001234')">Janes Plumbing</A>
><A HREF=vendorparts.jsp ONCLICK="submit_onclick('0005678')">Joes
>Plumbing</A>
>
>My problem is that I don't have a good way to set the bean value
>(setVendor) before the page in the link is called. I want to
>accomplish it with "xml style" setting the bean properties rather
>than mixing in alot of "pure java".
>
>1. If I try to use a "normal" java method, the submit_onclick
>method can not be found.
>2. If I try to use a function instead, I apparently can not pass
>a value to the function.
>3. I don't want to pass parms such as
>HREF=vendorparts.jsp?vendor=0001234 to prevent the user from
>looking at someone else's parts.
>
>Is there a better way to do this?
>
>Thanks in advance - and sorry for being so wordy.
>�
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:
http://archives.java.sun.com/jsp-interest.html
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.jsp
http://www.jguru.com/faq/index.jsp
http://www.jspinsider.com