Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

no element found at line 38 perl cgi scrpt error XML::Parser

Status
Not open for further replies.

jamsman

Technical User
Jul 22, 2005
38
DE
i am writing a cgi script, and get this error:

no element found at line 38, column 0, byte 1412 at /usr/local/lib/perl5/site_perl/5.8.5/sun4-solaris/XML/Parser.pm line 187

the begining of the script reads:

#!/u1/perl5.8.5/bin/perl -w
use CGI qw/:standard/;

use strict;
use XML::Simple qw:)strict);;
use Data::Dumper;
push(@INC, "../lib/perl5/5.8.5");
require "rtsLib.pl";
my $debug=0;
&printHeader;
my $colour = 'style="background-color:#CCCCCC"';
if (param("input")) {#if something is entered this happens
my $input2 = "/home/haiti/white/res.xml";

my $xml =new XML::Simple(KeyAttr=>'id', ForceArray=>1);

my $data =$xml->XMLin("$input2");

everything works fine untill: "my $data =$xml->XMLin("$input2");"

i get a blank web browser and the error above

any ideas thank you
 
thanks for the advise i was getting the XML from a database application writen by someone else no names!!! and assuming that it was well formed
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top