I am getting this error
Parse error: syntax error, unexpected T_STRING in /ho.../ssd/recording-goodbye.php on line 1
I have found that this line is causing this:
<?xml version="1.0" encoding="UTF-8"?>
I think this is because short tags are enabled on this server, it's a shared hosting account and I don't have access to the php.ini file. Is there a way I can perhaps set the headers or escape this line?
This is the full content of recording-goodbye.php
<?php echo '<?xml version="1.0" encoding="UTF-8"?>'; ?>
<Response>
<Say>Thanks for your recording. Here is what I heard</Say>
<Play><?php echo $_REQUEST['Reco开发者_开发百科rdingUrl']; ?></Play>
<Say>Goodbye</Say>
</Response>
This fixed it
<?php echo '<?xml version="1.0" encoding="UTF-8"?>'; ?>
Try the technique described here: http://www.bin-co.com/php/articles/using_php_short_tags.php
It involves treating your xml file so that when it's interpreted by a php configuration using short tags, it will still come through as XML.
精彩评论