I wrote file.pl<?xml version="1.0" encoding="utf-8" ?> <SDForm> <Form name="cmdb_cohesion.html" lang="en_US"> <ResourceString> <tag>en</tag> <value>en</value> </ResourceString> <ResourceString> <tag>Cohesion</tag> <value>Cohesion</value> </ResourceString> </Form> </SDForm>
and as a result of running this script i get such error "Not a HASH reference at: ...file.pl line 14. Please tell me why? What i need to do to fix this. thanksuse XML::Simple; use strict; my $xml = new XML::Simple; my $data = $xml->XMLin('cmdb_coh.xml'); print $data->{Form}->{ResourceString}->{value};
In reply to Not a hash reference... why? by toliyn
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |