File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes HTML, CSS and JavaScript and the fly likes generating dynamic tags  Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "generating dynamic tags  " Watch "generating dynamic tags  " New topic
Author

generating dynamic tags

Yell Srik
Ranch Hand

Joined: Mar 10, 2004
Posts: 61
Hi,
i need a small clarification regarding the following code
code for abc.html:


in the above code, the user on clicking the image is taken to
"program.html" where he has select boxes with options. he selects one
of the options and then clicks on a 'back' button and returns to
"abc.html"and here when he clicks on the submit button, the change()
function is to be executed and the following code is to be generated in
a separate window:


the value of the pic tag is a dynamic one and changes depending on the
option chosen by thte user.
code for program.html:


code for change():

i want the change() function to be executed only when the "submit"
button in "abc.html" is clicked.
how can i implement the above functionality? thanks in advance
Eric Pascarello
author
Rancher

Joined: Nov 08, 2001
Posts: 15376
    
    6
Isn't that what your code is already doing??
I am not sure what you are talking about.
Eric
Yell Srik
Ranch Hand

Joined: Mar 10, 2004
Posts: 61
Hi eric,
actually what i want to acheive is that: i want the change() function to be executed only when the submit button in "abc.html" is clicked. the exact point i need clarification is where to place the
change() function. currently i have placed it in the "abc.html" page but the change() takes its parameters from the form values in the "program.html" page.
the code i have given is not working and i am unable to detect what is the error. hope i have made things clear and waiting to hear from u.
Jeroen Wenting
Ranch Hand

Joined: Oct 12, 2000
Posts: 5093
you can't do it like that.
You're trying to access form values from an html file which is not loaded...
What you can do is put the second html page in a popup window and have the submit for that one pass something back to the calling page which uses it to set some hidden formfields.


42
Yell Srik
Ranch Hand

Joined: Mar 10, 2004
Posts: 61
hi,
thank u. i will work as u suggested.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: generating dynamic tags