Joined: Tue Jan 18, 2011 6:18 am
I have a simple problem.
I have a script that is trying to place a variable inside a XML tag but it's being ignored.
I am querying a web page that outputs xml and am trying to get the value between certain tags.
URL to query:
<?xml version="1.0" encoding="ISO-8859-1" ?>
So in the example above I want the value of 55 only.
Here's my script:
$LYNX -source "$URL?cmd=$CMD&dur=$DUR&vendor=$VENDOR" | $SED 's%.*<$TAG>\(.*\)</$TAG>.*%\1%p'
So I run:
./XMLData getNoOfSuccessfulTransactionsVendor 300 somecustomer nooftransctions
Unfortunately the $TAG variable is not being read correctly and I'm assuming it's because it's between ''
Any help please?