Beefy Boxes and Bandwidth Generously Provided by pair Networks Joe
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

capturing dynamic page

by cliffrubinmusic (Novice)
on May 09, 2012 at 21:18 UTC ( #969708=perlquestion: print w/ replies, xml ) Need Help??
cliffrubinmusic has asked for the wisdom of the Perl Monks concerning the following question:

Hello esteemed monks. Instead of just the form elements, I would like to write an entire webpage's source code to a file when the form is submitted. The webpage does not have a name to reference, as it is created dynamically. I'm sure I'm missing something simple here, but LWP and HTTP ask me to specify an http://url and this page doesn't have one. Please help. Thank you Cliff

Comment on capturing dynamic page
Re: capturing dynamic page
by Anonymous Monk on May 09, 2012 at 22:21 UTC

    The webpage does not have a name to reference, as it is created dynamically

    What does that mean?

    I'm sure I'm missing something simple here, but LWP and HTTP ask me to specify an http://url and this page doesn't have one.

    Well yes, yes you are. A web page has a web address, otherwise it isn't a web page. You need to learn about the internet to get an overall picture of how the internet works, , how tcp/ip, sockets, html, all fit together

      what I mean is: I use a script to create the web page, so, in the address heading it say: http://myscript.pl

      myscript.pl parses the form parameters and then decides which subs to call from another script, allthepagesandforms.pm, which then pulls a whole mess of info from a database and with this data finishes putting together a web page. BUT, in the address heading, it just says http://myscript.pl

      That's what I mean. What I'd like to do is take one of these dynamically produced web pages and, instead of just parsing the form parameters..store the entire web page source code along with the parameters in a file. can you help me with this? Thank you

        what I mean is: I use a script to create the web page, so, in the address heading it say: http://myscript.pl

        Um, that is not possible, unless myscript.pl is the name of your host

        What I'd like to do is take one of these dynamically produced web pages and, instead of just parsing the form parameters..store the entire web page source code along with the parameters in a file.

        Store it where?

        can you help me with this? Thank you

        See http://perldoc.perl.org/perlintro.html#Files-and-I%2fO and follow the links I gave you

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://969708]
Approved by ww
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (7)
As of 2014-04-24 09:23 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    April first is:







    Results (565 votes), past polls