Re: call HTML page from PERL
- From: sunilsushil@xxxxxxxxx
- Date: 28 Sep 2006 01:31:16 -0700
yes am sorry sir,
see i am having a login page which is saved as
(login.html).when i press login button the page's FORM Action calls my
perl script file( login.pl) which display some message as a html page
format shown:
login.pl file:
print "Content-Type: text/html\n\n";
print "<html> <head>\n";
print "<title>Minimal Input</title>\n";
print "</head>\n";
print "<body>\n";
print "<br>LOGIN Successfull<BR>";
print "</body> </html>\n";
after this i want to go back to my first page i.e my login page
(login.html ) how can i go back . thats what i meant by calling my old
page
Paul Lalli wrote:
sunilsushil@xxxxxxxxx wrote:
i have been writing program for file manupulation. by opening
, reading and appending..
i have a problem .
how can i call or open an HTML page from my script.
e.g my file : login.html
how to call this html page from my perl script..
That is non-sensical. What do you mean by "call" an html page. An
html page is not a program, and is not executed. It is pure text
(albeit in a special markup language, generally interpreted by web
browsers).
If you want to open the file for reading, you simply use the open
function, as described in
perldoc -f open
open my $html_fh, '<', 'login.html' or die "Cannot open login.html:
$!";
while (my $line = <$html_fh>) {
print "Line $. : $line";
}
If you want to do something else, you'll have to better describe your
goal, using terms that make sense.
Paul Lalli
.
- Follow-Ups:
- Re: call HTML page from PERL
- From: Chris Falzone
- Re: call HTML page from PERL
- References:
- call HTML page from PERL
- From: sunilsushil
- Re: call HTML page from PERL
- From: Paul Lalli
- call HTML page from PERL
- Prev by Date: incorrect output
- Next by Date: please advise help with regex
- Previous by thread: Re: call HTML page from PERL
- Next by thread: Re: call HTML page from PERL
- Index(es):