matthew9090 Posted March 31, 2011 Share Posted March 31, 2011 I have got a flash file that is stored in the database. So I fetch it and put it in a variable then put the variable in the flash embed code where the src is but the flash comes up blank. $file = "SELECT * FROM table WHERE column='$name'"; $file2 = mysql_query($sqlfile); $file3 = @mysql_fetch_assoc($file2); $file4 = $file3['gamefile']; //skip some code to html embed section <object width='550' height='400'> <param name='movie' value='valuename'> <embed src='$file4' width='550' height='400'> </embed> </object> then the page comes up with a white box which when you hover over it says 'file not loaded'. Link to comment https://forums.phpfreaks.com/topic/232308-show-flash-file-from-database/ Share on other sites More sharing options...
blacknight Posted March 31, 2011 Share Posted March 31, 2011 $file = "SELECT * FROM table WHERE column='$name'"; $file2 = mysql_query($sqlfile); should be $sqlfile = "SELECT * FROM table WHERE column='$name'"; $file2 = mysql_query($sqlfile); Link to comment https://forums.phpfreaks.com/topic/232308-show-flash-file-from-database/#findComment-1195049 Share on other sites More sharing options...
matthew9090 Posted March 31, 2011 Author Share Posted March 31, 2011 when i view the html of the page it comes up with the embed src as nothing Link to comment https://forums.phpfreaks.com/topic/232308-show-flash-file-from-database/#findComment-1195054 Share on other sites More sharing options...
AbraCadaver Posted March 31, 2011 Share Posted March 31, 2011 You're not echoing the var in the HTML: <embed src="<?php echo $file4; ?>" width="550" height="400"> Link to comment https://forums.phpfreaks.com/topic/232308-show-flash-file-from-database/#findComment-1195122 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.