Hi,

2012/12/10  <[email protected]>:
> Yes, it was my first try, i even replace request.dynamic by playlist.safe...

So, if you have tried with a dummy script, was it working or was it not working?

> Here is my php script (i just add the annotate yesterday...)
>
>
>
> <?php
>
> $link = mysql_connect('localhost', 'user', 'pass') or die('Impossible de se 
> connecter : ' . mysql_error());
> mysql_select_db('lgt') or die('Impossible de sélectionner la base de 
> données');
>
> //Logique de sélection de base sur random...
> $query = 'SELECT ID, songtype, duration, artist, title, filename FROM songs 
> WHERE songtype=\'S\' and weight > 10 and RAND() > 0.9 ORDER BY RAND() LIMIT 
> 1';
> $result = mysql_query($query) or die('Échec de la requête : ' . 
> mysql_error());
>
> if (!$result) { die('Impossible d\'exécuter la requête :' . mysql_error());}
>
> $ID = utf8_encode(mysql_result($result, 0, 'ID'));
> $songtype = utf8_encode(mysql_result($result, 0, 'songtype'));
> $duration = utf8_encode(mysql_result($result, 0, 'duration'));
> $artist = utf8_encode(mysql_result($result, 0, 'artist'));
> $title = utf8_encode(mysql_result($result, 0, 'title'));
> $filename = utf8_encode(mysql_result($result, 0, 'filename'));
>
> echo 
> utf8_encode("annotate:ID=\"$ID\",songtype=\"$songtype\",duration=\"$duration\",artist=\"$artist\",title=\"$title\":$filename");
>
> mysql_free_result($result);
> mysql_close($link);
>
> ?>
>
>
>
> In summary
>
> this snippet works well (with playlist.safe but not with playlist only):
>
> flux = 
> rotate(weights=[1,1],[playlist.safe("/pathtofile/"),playlist.safe("/pathtofile/")])
> flux = crossfade(flux)
>
>
> But this one stream blank (or whatever you put in the fallback) :
>
> flux = 
> rotate(weights=[1,1],[request.dynamic(myrequest),request.dynamic(myrequest)])
> flux = crossfade(flux)
>
>
> I think the problem come from clock affectation (just a supposition, i'm 
> quite new on liquidsoap, i'm still in a kind of discovery stage with this 
> soft...)
> Because i read somewhere in the documentation that the cross operator is only 
> possible between track of the same source, or between source sharing the same 
> clock.
> At least it's what i understand, perhaps i make confusion... Nevertheless i'm 
> still searching...

The clock situation is fine. There are a lot of assumptions involved
with running a php script in command line. Therefore, I'd like to ask
you again if you have tried with a dummy script like "echo
'/path/to/file.mp3'" and if the script was working in this case..

Thanks,
Romain

------------------------------------------------------------------------------
LogMeIn Rescue: Anywhere, Anytime Remote support for IT. Free Trial
Remotely access PCs and mobile devices and provide instant support
Improve your efficiency, and focus on delivering more value-add services
Discover what IT Professionals Know. Rescue delivers
http://p.sf.net/sfu/logmein_12329d2d
_______________________________________________
Savonet-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/savonet-users

Reply via email to