|
Installation of RSS audio feed software (pod cast) |
|
The upload software is written in Perl. PHP, by default, is limited to 2MB file uploads. Many audio files are larger regularly being 3MB or more. The XML/RSS feed software, however, is written in PHP. A PHP version of the file uploader is available if your hosting company has increased the PHP 'upload_max_filesize' var. |
Outline
|
|
Details Download zip package and unzip The zip package will contain the following files: demoUpload.pl, podList.txt, rssCast.php, and basicUploadForm.html. The package also matches the directory structure (tree) the software is set up for. For example audio files are called from a directory called 'audio' and the RSS element data is derived from the 'podList.txt' file in the records directory so the zip file is packaged with those directories. |
Customize script with your domain name Open uploadDemo.pl, feed.php and basicUploadForm.html in a text reader and do a search and replace changing www.MyDomainName.com to your domain name. You might also want to change the name of demoUpload.pl to upload.pl. If you do change the name, change the name in the action attribute of the html form tag in the basicUploadForm.html file as well. That would be from: <form name = "SONG_UPLOAD_FORM" action = "http://www.MyDomainName.com/cgi-bin/demoUpload.pl" method = "post" enctype="multipart/form-data"> to: <form name = "SONG_UPLOAD_FORM" action = "http://www.YourDomainName.com/cgi-bin/upload.pl" method = "post" enctype="multipart/form-data"> |
Upload 'demoUpload.pl' to cgi-bin dir Or 'upload.pl' if you've already changed the name. The html form tag will be looking for this file. |
Chmod 'demoUpload.pl' to 700 You must also set file permissions on a UNIX server by using the 'chmod' command. I recommend setting file permissions to '700' or put another way change owner file permissions to read, write, and execute. Contact www.programsplus.us if you have any questions about this. Using the chmod command can be confusing depending on the type of ftp software you're using. Make sure your click refresh if you using WSFTP. |
Make directories: The feed.php and demoUpload.pl software looks for files in the audio, audio/podCastDescriptions, records, and RSS directories. Make sure these directories are created if they aren't already. If you need to change the name of any of these directories make sure your find the corresponding lines in the code and change the reference as well. It's important to note that the Perl and PHP software will throw an error if it they don't find any of these directories. It may also be important to note that the enctype="multipart/form-data" attribute of the html form tag is necessary for file uploads to take place. The title, artist and description text fields are self explanatory except you may want to consider that the description field is stored in the description file that's called by the RSS Feed (audio/podCastDescription/xyzDescription.txt). Every music file uploaded needs a corresponding text file. It depends on the device. Some may only display up to fifty characters some more. You may want to restrict the number of characters either with JavaScript or in the demoUpload.pl file. Also since RSS has no name element that we can use for artists, the artist name is combined with the description field in this code. You may want to pursue more eloquent scripting for a customer base. |
Upload podList.txt to 'records/' directory After you've created the 'records/' directory upload the 'podList.txt' file to it. It's an empty file that will be appended by the demoUpload.pl software code. |
Upload 'feed.php' to RSS directory After you've created the 'RSS/' directory upload the 'feed.php' file. This is the file audio rss feed aggregators read (pod casts). Aggregators only read XML but the php script generates the XML script the aggregator needs. |
Install RSS button Finally install the rss.gif as a link to your feed.php file. |
Upload 'basicUploadForm.html' This is the basic html script for uploading a file. It has no style or scripting information. You may want to integrate it into another web page. |
| XML code example |