parameters~

A

Anonymous

Guest
what is the flash parameters need to be ad on in my php coding.. coz b4 this, i just put the .gof image.. when i change it to .swf.. it doesn't work..
can i know the paramaters.. an example would help~ thanx~
 
Are you just trying to put the path/filename to the Flash file in the SRC of your IMG tag? 'Cause that's not gonna work. 'Cause a Flash file isn't an image. You have to use the object tag. As per usual, Google has the answer:

http://www.google.com/search?&q=flash+object+tag
 
Yeh swirlee is right!
Here is a lil' idea cinoz. You can try it, but i'm not sure if that regex is right :D
Code:
<?php

$img = 'mypic.swf';

if ( preg_match ('/^.swf/i', $img) ) {

    echo "<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0">
    <param name="movie" value="' . $img . '">
    <param name="quality" value="high">
    <param name="menu" value="false">
    <embed src="' . $img . '" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash"></embed>';				 				 
}
else {
    echo '<img src="' . $img . '">';		 
}

?>
 
Back
Top