creating new Playlist using php (externally)
  • Hi folks 
    I was wondering how the cc_playlist fills the mtime, and utime i.e.where does it get the time and how / where does is it computed.


    Note : i am assuming that mtime is "time the playlist was created" and utime is "the last time the playlist was update", Please do correct me if i'm wrong.

    Regards
  • 5 Comments sorted by
  • Also how does airtime update the the "position" field in the cc_playlistcontents, and where. 
    As i want to alter the database straight away instead of using the application to add and move tracks into a playlist 
  • Vote Up0Vote Down hoerichhoerich
    Posts: 627Member, Airtime Moderator
    I must admit, I cannot answer any of your questions, but I want to link in on this topic, cause I think you are heading in the same direction as I do.

    while browsing through the FAQ for adding-user--per-command http://en.flossmanuals.net/airtime/the-airtime-user-command/,
    I thought about having a similar possibility for handling shows or playlists?

    For an admin having knowledge of terminal-commands, it would be much easier to create a show or add a playlist/file/webstream to a show via terminal (maybe remote) than doing this via GUI.
    I know other Radio Automation Systems which can be controlled through http-commands via webbrowser.

    Wouldn't this be nice?
    Official Airtime Forum Manager
    --------------------------
    Most of the time an issue is located between keyboard and chair.
  • This will be sweet, is it available in 2.31.
    Unfortunately its a small school project and i have a deadline for my code of this friday, so i'm not sure i'll have time to incorporate it among the other things.... 

    BTW I have managed to create new playlist/ manipulate the other playlist , put in new track, and remove track all based on track ID ( for a REST based API)  by altering the database, instead of using the Application, 
    Post edited by Anselm Mathias at 2013-04-09 14:48:19
  • Vote Up0Vote Down hoerichhoerich
    Posts: 627Member, Airtime Moderator

    BTW I have managed to create new playlist/ manipulate the other playlist , put in new track, and remove track all based on track ID ( for a REST based API)  by altering the database, instead of using the Application, 


    wow, this would be great to test! are you able to publish the code?
    adding playlists to shows would be the peak for me yet.

    for what I wrote in the earlier comment... these are all wishes. nothing implemented yet!
    Post edited by hoerich at 2013-04-10 06:11:31
    Official Airtime Forum Manager
    --------------------------
    Most of the time an issue is located between keyboard and chair.
  • lol :) 



    its not finished, so some things might not work....

    place the contents of the zip file, "api" folder and the "vendor" folder into the /usr/share/airtime/public/ folder

    permissions

    me@radio:/usr/share/airtime/public$ ls -al
    total 60
    drwxr-xr-x 10 root root 4096 Apr 10 14:12 .
    drwxr-xr-x  8 root root 4096 Feb 28 15:18 ..
    drwxrwxrwx  4 root root 4096 Apr 10 14:07 api
    drwxr-xr-x  9 root root 4096 Mar  4 15:49 css
    -rw-r--r--  1 root root 4286 Feb 28 15:18 favicon.ico
    -rw-r--r--  1 root root  832 Feb 28 15:18 .htaccess
    drwxr-xr-x  3 root root 4096 Feb 28 15:18 images
    -rwxr-xr-x  1 ftp  ftp  2461 Mar 29 16:51 index.php
    drwxr-xr-x  2 root root 4096 Feb 28 15:18 install
    drwxr-xr-x 20 root root 4096 Feb 28 15:18 js
    -rw-r--r--  1 root root   31 Feb 28 15:18 robots.txt
    drwxr-xr-x  2 root root 4096 Mar 26 19:38 test
    drwxr-xr-x  3 root root 4096 Feb 18 05:56 vendor
    me@radio:/usr/share/airtime/public$


     and then test if it works 
    eg

    PS: sorry i'm a bit messy