in reply to Re: Print out an XML file to browser
in thread Print out an XML file to browser
Hi been42
That is exactly what I am looking to do. I tried your start_html but it just returns a time stamp to the browser. Am I missing something more fundemental? I'm a bit of a CGI novie, but here is what I have so far:
optput:Mon Feb 19 21:34:25 2007 processremote.cgi: readline() on closed filehandle XMLFILE at /my/upload/path/processremote.cgi line 15.
That is exactly what I am looking to do. I tried your start_html but it just returns a time stamp to the browser. Am I missing something more fundemental? I'm a bit of a CGI novie, but here is what I have so far:
optput:Mon Feb 19 21:34:25 2007 processremote.cgi: readline() on closed filehandle XMLFILE at /my/upload/path/processremote.cgi line 15.
#!/usr/bin/perl use strict; use warnings; use CGI qw(:standard); use CGI::Carp qw(fatalsToBrowser); print header; print start_html(-head=>meta({-http_equiv => 'Content-Type', -content => 'text/xml'})); open(XMLFILE, "/my/upload/path/master.xml"); while (<XMLFILE>){ print $_; }
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^3: Print out an XML file to browser
by virtualsue (Vicar) on Feb 20, 2007 at 05:56 UTC | |
by lakeTrout (Scribe) on Feb 20, 2007 at 06:58 UTC | |
by been42 (Curate) on Feb 20, 2007 at 14:55 UTC | |
Re^3: Print out an XML file to browser
by siva kumar (Pilgrim) on Feb 20, 2007 at 05:41 UTC | |
by virtualsue (Vicar) on Feb 20, 2007 at 06:26 UTC | |
by lakeTrout (Scribe) on Feb 20, 2007 at 05:55 UTC |
In Section
Seekers of Perl Wisdom