I have a perl script that calls a curl command via backticks.
Because of the locked down environment I work in, I can not add any modules to the basic perl install ( 5.05 on most or 5.8.8 on the newest machines).
I have a problem with the @ in a curl command that allows input from a file: curl -d@filename
perl compalins that :
Can't use string ("home/xymon/server/ext/ch
as an ARRAY ref while "strict refs" in use at ./xy_weblogic_chk.pl line 155.
`$CURL --connect-timeout 5 -m 15 -d@$XML_FILE http://$opt_IP/middleware
2>&1 | grep "/result" > $infile` ;
this cmmand works fine in a shell script
How do I escape or fix the command to get it to work in backticks or other solution.
Thanks in advance.