Hello,
This is part of my PHP code:
I get this error when simply opening the document ($port is nothing/not defined).Code:<?php if($port != !$port) { $port = $_POST['port']; $handle = fopen('/home/XXXXXXXXXXX/public_html/players/'. $port .'.asx', "x+"); $line1 = '<ASX version="3.0">' $line2 = '<title>Radio</title>' $line3 = '<entry>' $line4 = ' <title>Radio</title>' $line5 = ' <author>Tech-Hosts.co.uk</author>' $line6 = ' <ref href="http://shoutcasts.tech-hosts.com:'. $port .'/"/>' $line7 = '</entry>' $line8 = '</ASX>' fwrite($handle, $line1."\n") fwrite($handle, $line2."\n") fwrite($handle, $line3."\n") fwrite($handle, $line4."\n") fwrite($handle, $line5."\n") fwrite($handle, $line6."\n") fwrite($handle, $line7."\n") fwrite($handle, $line8."\n") fclose($handle);
Line 45 is:Code:Parse error: syntax error, unexpected T_VARIABLE in /home/XXXXXXXX/public_html/playercode.php on line 45
I'm not very good at PHP, I just pick things up as I go along and I've never spent time learning it. I'm trying to code a simple PHP script so I knew I'd need some real help along the way.Code:$line2 = '<title>Radio</title>'
+rep to the first person to give a correct solution.
Thanks.







