het maken van een asx

Overzicht Reageren

Sponsored by: Vacatures door Monsterboard

Dennis S

Dennis S

07/10/2006 14:08:00
Quote Anchor link
Ik ben nu bezig met het maken van asx bestand. Het creeren van de asx dmv php lukt goed, maar als ik hem open dan zie ik geen lijst.

Maar als ik de asx bestand handmatig maak dan laat ie wel een lijst zien.

Weet iemand een oplossing.

M'n code:
Code (php)
PHP script in nieuw venster Selecteer het PHP script
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
<?php
header('Content-type: audio/x-ms-wma');
$path = 'files/audio/Junkie_XL';

echo '<asx version="3">
<title>'
.$path.'</title>
<!-- Created by the IMC Playlist generator -->'
.PHP_EOL;

$dir_handle = @opendir($path) or die('Unable to open   '.$path);
while ($file = readdir($dir_handle))
{

    $filename = $file;
  
       if($file!='.' && $file!='..')
          echo '<entry><ref href="http://localhost/imc/'.$path.'/'.$file.'" /><title>'.$file.'</title></entry>'.PHP_EOL;
        
}

closedir($dir_handle);
echo '</asx>';

?>
Gewijzigd op 01/01/1970 01:00:00 door Dennis S
 
PHP hulp

PHP hulp

29/03/2024 12:24:59
 
B a s
Beheerder

B a s

07/10/2006 14:21:00
Quote Anchor link
Misschien is het handig om de output van je zelf geschreven asx bestand te tonen en één van de door PHP gegenereerde?
 
Dennis S

Dennis S

07/10/2006 14:34:00
Quote Anchor link
door php:
Code (php)
PHP script in nieuw venster Selecteer het PHP script
1
2
3
4
5
6
7
8
9
10
11
12
<asx version="3">
<title>files/audio/Junkie_XL</title>
<!-- Created by the IMC Playlist generator --><entry><ref href="http://localhost/imc/files/audio/Junkie_XL/Junkie_xl_-_Drift_away.mp3" /><title>Junkie_xl_-_Drift_away.mp3</title></entry>
<entry><ref href="http://localhost/imc/files/audio/Junkie_XL/Junkie_xl_-_Even_in_this_moment.mp3" /><title>Junkie_xl_-_Even_in_this_moment.mp3</title></entry>
<entry><ref href="http://localhost/imc/files/audio/Junkie_XL/Junkie_xl_-_Honey.mp3" /><title>Junkie_xl_-_Honey.mp3</title></entry>
<entry><ref href="http://localhost/imc/files/audio/Junkie_XL/Junkie_xl_-_Ive_got_a_xerox_to_copy.mp3" /><title>Junkie_xl_-_Ive_got_a_xerox_to_copy.mp3</title></entry>
<entry><ref href="http://localhost/imc/files/audio/Junkie_XL/Junkie_xl_-_Such_a_tease.mp3" /><title>Junkie_xl_-_Such_a_tease.mp3</title></entry>
<entry><ref href="http://localhost/imc/files/audio/Junkie_XL/Junkie_xl_-_Today.mp3" /><title>Junkie_xl_-_Today.mp3</title></entry>
<entry><ref href="http://localhost/imc/files/audio/Junkie_XL/Junkie_xl_-_We_become_one.mp3" /><title>Junkie_xl_-_We_become_one.mp3</title></entry>
<entry><ref href="http://localhost/imc/files/audio/Junkie_XL/Junkie_xl_-_Yesterdays.mp3" /><title>Junkie_xl_-_Yesterdays.mp3</title></entry>
<entry><ref href="http://localhost/imc/files/audio/Junkie_XL/Junkie_xl_-_Youthfull.mp3" /><title>Junkie_xl_-_Youthfull.mp3</title></entry>
</asx>


zelf:
Code (php)
PHP script in nieuw venster Selecteer het PHP script
1
2
3
4
5
6
7
<asx version="3">
<title>/files/audio/Junkie_XL/</title>
<!-- Created by the IMC Playlist generator -->
<entry><ref href="http://localhost/imc/files/audio/Junkie_XL/Junkie_xl_-_Drift_away.mp3" /><title></title></entry>
<entry><ref href="http://localhost/imc/files/audio/Junkie_XL/Junkie_xl_-_Even_in_this_moment.mp3" /><title></title></entry>
<entry><ref href="http://localhost/imc/files/audio/Junkie_XL/Junkie_xl_-_Honey.mp3" /><title></title></entry>
</asx>
Gewijzigd op 01/01/1970 01:00:00 door Dennis S
 
PHP Newbie

PHP Newbie

07/10/2006 15:16:00
Quote Anchor link
volgens mij geef je der verkeerde header mee, maar dat weet ik niet zeker
 
Dennis S

Dennis S

07/10/2006 15:18:00
Quote Anchor link
met deze headers werkt het ook niet

.asx application/x-mplayer2
.asx video/x-ms-asf
.asx video/x-ms-asf-plugin

Hij wordt wel in mediaplayer geopend, alle entry's worden afgespeeld, maar er komt geen lijst. In winamp wel.

bron:
http://www.webmaster-toolkit.com/mime-types.shtml

of:
http://support.microsoft.com/kb/288102
Gewijzigd op 01/01/1970 01:00:00 door Dennis S
 



Overzicht Reageren

 
 

Om de gebruiksvriendelijkheid van onze website en diensten te optimaliseren maken wij gebruik van cookies. Deze cookies gebruiken wij voor functionaliteiten, analytische gegevens en marketing doeleinden. U vindt meer informatie in onze privacy statement.