Jump to content

syntax error with embede video player


s4salman

Recommended Posts

hi

i am getting syntax error in the following php code. Can any one help me in this regard.

 

 

<?php

echo "<script type=\"text/javascript\" src=\"http://funxy.com/sabaadmin/swfobject.js\"></script>




<script type=\"text/javascript\">



var s1 = new SWFObject("http://www.funxy.com/sabaadmin/flvplayer.swf","single","320","280","7");



s1.addParam("allowfullscreen","true");



s1.addVariable("file","$player");



s1.addVariable("image","$image");



s1.addVariable("width","320");



s1.addVariable("height","280");



s1.write("player1");



</script>";

?>

Link to comment
https://forums.phpfreaks.com/topic/234990-syntax-error-with-embede-video-player/
Share on other sites

thank you for your reply , this is the error :

 

Parse error: syntax error, unexpected T_STRING, expecting ',' or ';' in /home/funxy/public_html/salmobile.info/3gp-videos-download2.php on line 233

 

i am attaching the php file.

 

[attachment deleted by admin]

your gonna have to escape the quotes all the way through that, else change echo " to echo ' and get rid of the first escapes. line 224 and 233.

 

or just replace lines 222 to 263 with this:

 

<?php
echo '<script type="text/javascript" src="http://funxy.com/sabaadmin/swfobject.js"></script>
<script type="text/javascript">
var s1 = new SWFObject("http://www.funxy.com/sabaadmin/flvplayer.swf","single","320","280","7");
s1.addParam("allowfullscreen","true");
s1.addVariable("file","$player");
s1.addVariable("image","$image");
s1.addVariable("width","320");
s1.addVariable("height","280");
s1.write("player1");
</script>';
?>

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.