![]() |
|
Think about Loose Coupling | |
PerlMonks |
How to pass form data to a onclick=javascript:new.window perl scriptby Asgaroth (Novice) |
on Feb 17, 2004 at 09:48 UTC ( [id://329544]=perlquestion: print w/replies, xml ) | Need Help?? |
Asgaroth has asked for the wisdom of the Perl Monks concerning the following question:
Hi, I know this question (or derivatives of it) have been asked before, I found a load in the super search and have tried a couple of the recommendations, but, I always end up coming short. I am 100% positive, there must be something I am missing, but, due to my minimal perl/html/javascript knowledge, I thought I would come to the monestry and seek the wisdom of those who came before.... My setup is as follows: I have 2 perl scripts, 1 show_page.pl This script displays a web page and prints a form with 2 "questions" a system name and a message. When the user presses the submit button, a new window opens which "should" run the second script, 2 create_data.pl This script takes the 2 parameters passed from the above script and converts all text files in a directory to html, displaying output to the new window as it does it (this does not happen though). Now, the problem I am havin is: 1 When I click on the submit button, the new browser window opens, but my parameters dont appear to have been passed accross to the new script, and, the original window (show_page) executes the 2nd script and displays it in the original window????, an excerpt of my code follows: 1 In show_page.pl
If I remove the onclick bit, and add an action section to the start_form method to point to the create_data.pl script, all works fine, so I know the scripts (perl) bits appear to be ok, but when I open the new window, I seem to lose my parameters??? Can anyone please help with this coz I'm starting to lose hair with this, I'm sure I am overlooking something so trivial here, that when someone points it out, I will more than likely kick myself (or someone will kick me). Could it also possibly be that I am going about this in the wrong way, is there any other possible solution to what I am trying todo here?? Thanks Your humble servent Asgaroth
Back to
Seekers of Perl Wisdom
|
|