Menu DEVPPL Search
157.886
MEMBERS
15.939
TOPICS
63.222
POSTS
  562
FLASH GAMES
7.717
TUTORIALS
 

Login

E-mail:
Password:

Play a Mysql Blob (wave) file?

0

Loading

Play a Mysql Blob (wave) file?

Postby Estes » Thu May 17, 2007 5:49 pm

I am trying to pull a wave/riff file from mysql and make it playable.

Below is the php which is not working and I have been told that it will not work without referencing a second page, which I want to avoid.

Anyone know of a Java app that would do it?

Code-

$query = 'SELECT `easy1_a_v`.`sound`
FROM easy1_a_v
ORDER BY `easy1_a_v`.`newlang` ASC';
$result = mysql_query($query) or die('Query failed: ' . mysql_error());

echo "<CENTER><H1><table BORDER=\"4\" CELLPADDING=\"2\" CELLSPACING=\"2\" WIDTH=\"50%\">\n";
while ($line = mysql_fetch_array($result, MYSQL_ASSOC)) {
echo "\t<tr>\n";
foreach ($line as $col_value) {
echo "\t\t<td><embed src=($col_value)
width=\"200\" height=\"240\" href=(col_value) target=\"quicktimeplayer\"></td>\n";
}
echo "\t</tr>\n";
}
echo "</table></H1></CENTER>\n";

Result-

<Big empty space where the audio player icon would normally be>...

...��WAVEfmt���U�[1]�À]...

...<a lot of RIFF (BLOB from mysql) code>...

...ÿÿÿÿÿÿÿÿÿÿÿÿÿÿ) width="200" height="240" href=(col_value) target="quicktimeplayer">

Thanx, Alan
Estes
 
Reputation: 0
Posts: 2
Joined: Thu May 17, 2007 2:58 pm
Highscores: 0
Arcade winning challenges: 0

Play a Mysql Blob (wave) file? - Sponsored results

Sponsored results

Login to get rid of ads

 

^ Back to Top