Dec 04, 2008, 01:05 AM *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
Search via SMF or Google: modx forums all of modxcms.com web
  MODxCMS.com   Forums   Help Login Register  
Pages: [1] 2 3 4   Go Down
  Print  
Author Topic: [Snippet] MODcast - MODx Podcast / Podcasting snippet  (Read 19428 times)
0 Members and 1 Guest are viewing this topic.
Dr. Scotty Delicious
Coding Team
*
Posts: 1,172


Dr. of Fine Pirate Arts


WWW
« on: May 03, 2006, 04:03 AM »

MODcast & MODcastAdmin 0.2.6
   by Scotty Delicious
   http://www.scottydelicious.com
   Made on a Mac™ (OS X 10.4.6) using TextMate [ http:\\:www.macromates.com ]


based on dircaster 0.4 by Ryan King (http://www.shadydentist.com)
ID3v2.x tag support added by Warren Stone <fasttr [at] gmail [dot] com> and
utilizing getid3 library by James Heinrich <info [at] getid3 [dot] org>, 
http://www.getid3.org. iTunes specific tag support by Warren Stone

The MODcast snippet generates an iTunes XML podcast feed from a folder of audio or video files.

The MODcastAdmin snippet asks the user to create a new feed and then presents the user with an easy to manage form requesting configuration data, then writes that data to a configuration file with the same name as the feed. Example, a user creates a new feed called "mytalkshow".  MODcastAdmin takes all their preferences and stuffs them into a file called mytalkshow.inc.php. To call the snippet, one would simply type [[MODcast? &feed=`mytalkshow`]].  All their prefs would be loaded automatically by the snippet.  NEW!   You can also use MODcastAdmin to edit and manage existing config files.  Simply select the name of the "feed".inc.php file you with to edit from the drop down list, press "Load Config File", "Continue", and there are all your preferences, already in the form, just begging to be edited or embellished!

So, again, you must call the admin snippet uncached [!MODcastAdmin!], and the page where you call MODcast from must have the template set to "blank", and its content type set to text/xml.  all you need to do is specify the feed!

I have this snippet creating a podcast of all my music.
the music page is:  http://www.scottydelicious.com/music.html
and the podcast XML is: http://www.scottydelicious.com/modcast.xml



CHANGE LOG:
     See MODcast_README.txt

TO DO:
     Add file upload management (sill only 50% done)
     Change if/else statements to switch/case (100% done)

     Add more descriptive/helpful comments (forever ending, never done)
     Clean up the code (Got a damn good start today)

KNOWN BUGS:
     #1) the subcategory gets reset everytime a saved config file is reloaded. !RESOLVED!
     #2) Check boxes don't work. !RESOLVED!
     #3) the subcategory doesn't work at all in KHTML/WebKit based browsers (safari, shiira, konqueror...).


later

-sD-
scotty Delicious

* MODcast_MODcastAdmin_v0.2.6.zip (409.87 KB - downloaded 441 times.)
* MODcast_README.txt (7.32 KB - downloaded 456 times.)
« Last Edit: May 12, 2006, 12:45 AM by ScottyDelicious » Logged

We pillage, we plunder, we rifle and loot. Drink up me 'earties, Yo Ho!
We kidnap and ravage and don't give a hoot. Drink up me 'earties, Yo Ho!
Yo Ho, Yo Ho! A pirate's life for me.
banzai
Testers
*
Posts: 857


MODx Italia


WWW
« Reply #1 on: May 03, 2006, 04:16 AM »

Thanks for sharing Scotty - nice snippet Wink
Logged

MODx Websites Showcase 
Add your site to www.modx.it!
-----------------------------------------------------
FREE MODx Templates
www.tattoocms.it
-----------------------------------------------------
VIDEO: whats new in MODx 0.9.5   | VIDEO: MODx PHP Application Framework  |  bubuna.com - Web & Multimedia Design
zi
MODx Special Forces /
Administrator
*
Posts: 3,014


May Peace Be On You


WWW
« Reply #2 on: May 03, 2006, 07:07 AM »

Nice snippet Scotty! Smiley

Thanks for sharing.

regards,

zi
Logged

“Internet Explorer’s CSS rendering: WYSIWTF”. — someone genius
--------------------------------------------------
kickass
Full Member
***
Posts: 159



WWW
« Reply #3 on: May 03, 2006, 12:14 PM »

Very cool! Check it off the wishlist!
Logged

"I'd love to change the world but I can't find the source code . . ."

Custom ModX Templates
Dr. Scotty Delicious
Coding Team
*
Posts: 1,172


Dr. of Fine Pirate Arts


WWW
« Reply #4 on: May 03, 2006, 03:41 PM »

There are a few additions on my todo list:

1) Turn this into a module + Snippet combo.
     you will be able to set the configuration through a form.
     the preferences you set in the module would be passed to the snippet
     so it could be called simply as [[MODcast]] on a blank template, text/XML page.

2) Add an "Upload Media" option to the module so you can do all the management from the back end.

I feel like I may be missing something, If you have any ideas, please post them here.

-sD-

Logged

We pillage, we plunder, we rifle and loot. Drink up me 'earties, Yo Ho!
We kidnap and ravage and don't give a hoot. Drink up me 'earties, Yo Ho!
Yo Ho, Yo Ho! A pirate's life for me.
kickass
Full Member
***
Posts: 159



WWW
« Reply #5 on: May 03, 2006, 04:04 PM »

Oh, Scotty, you are delicious! Wink

Yes, that would all be good, since, for instance, the client who asked for this feature for the site I'm currently building knows just enough about html to give me a headache . . . (yes, Barry, I realize you might be reading this, but I've already told you that in person the last time I had to fix your site  Grin) So making podcasting "idiot-proof" would be a very good thing.

No great hurry, I'm still building this one out . . . but I suspect some people might need it yesterday.
Logged

"I'd love to change the world but I can't find the source code . . ."

Custom ModX Templates
davidm
Marketing & Design Team
*
Posts: 6,777


The best way to predict the future is to invent it


WWW
« Reply #6 on: May 03, 2006, 06:37 PM »

My, my this is a kickass snippet (no pun intended Wink )

I mean this is one of those things that will get bloggers out of the wood to adopt MODx as their favorite blogging tool... this, NewsListing and MaxiGallery and soon Trackbacks... why do you need WordPress or Loudblog for ?

Grin

I still have to install and test, but I just love the concept, and the name... man that was a sweet pick !!!
Hats off !
Logged

.: nodeo.net : Pour un web libre, moderne et ouvert ! :: david-molliere.net : Suivez en "live" mes expérimentations et billets sur les CMS et autres applications web :.

*** Forums modxcms.fr Participez à l'élaboration du site MODx francophone ! ***

! Nouveau !  En live, ne manquez pas les news de modxcms.fr sur Twitter   ! Nouveau !

MODx est l'outil idéal pour les developpeurs et webdesigners qui cherchent un framework de gestion de contenu hautement flexible et performant, tout en étant simple d'accès pour les utilisateurs finaux.

Config : Apache 2.2.8 - MySQL 5.0.45 - PHP 5.2.6 | Debian 4.0 (Etch)

Réalisations sous MODx : | pargade-notaires.fr | soleil.info | gican.asso.fr | michelez-notaires.com | amadom.gerondicap.com | jocelyne-violet.net
Pixel Stuff
Sr. Member
****
Posts: 251



WWW
« Reply #7 on: May 03, 2006, 06:56 PM »

When you create the module, it would be nice to allow the date to be set on uploaded items rather than using the time stamp on the upload.  Multiple reasons.
  • If you move the podcast archive all the dates get reset.
  • The specific need I have is that we record live events and podcast them later in the week.  I would rather have the date of the event show on the podcast rather than the date we uploaded it which might be the next day.

Second, is there currently any way to specify the Description field for the individual podcasts? I haven't found it yet.  Ccould we get a paramater to pull that description from the MP3s comment field until a full entry form is made in the module.


« Last Edit: May 03, 2006, 07:07 PM by jbjones » Logged
Pixel Stuff
Sr. Member
****
Posts: 251



WWW
« Reply #8 on: May 03, 2006, 07:12 PM »

I read somewhere back when hand coding these things. Is the RSS tag of a Podcast actually supposed to read like this?

Code:
<rss xmlns:itunes="http://www.itunes.com/DTDs/Podcast-1.0.dtd" version="2.0">

I'm just wondering.  Mine is currently only reading

Code:
<rss version="2.0">

Still seems to work just fine though. 
« Last Edit: May 03, 2006, 07:14 PM by jbjones » Logged
Briggsy
Sr. Member
****
Posts: 372



WWW
« Reply #9 on: May 03, 2006, 10:20 PM »

Sweet, been away for a month+, to come back and see this great Snippet. I can stop messing around with other 3rd party tools and lookat  genuine MODx implimenation.

Cheers  Smiley
Logged

Emergency Management Academy of New Zealand
      http://www.emanz.ac.nz

MODx Sandbox   Login: sandbox  Password: castle

Admin Sandbox   Login: sandbox  Password: castle
Dr. Scotty Delicious
Coding Team
*
Posts: 1,172


Dr. of Fine Pirate Arts


WWW
« Reply #10 on: May 05, 2006, 11:59 AM »

Just an update,
I have the Podcast management snippet for [[MODcast]] half done.  It is called "[[MODcastAdmin]]".  The configuration part works awesome.  You fill out a web form once to configure every aspect of the snippet so the only call would be [[MODcast]] Grin.  I hated the fact that the snippet call was like 400 characters long Wink.  I need to scrub up the file upload half of [[MODcastAdmin]] because there are some SERIOUS security issues with it now, and it only uploads a file (no display of files already uploaded, no settings for timestamp like jbjones suggested), but I am hoping to get a ton of work done on MODcast/MODcastAdmin v0.3 this weekend because it is my fiancé's bridal shower, so I am kicked out of the house.  Cry

later

-sD-
Logged

We pillage, we plunder, we rifle and loot. Drink up me 'earties, Yo Ho!
We kidnap and ravage and don't give a hoot. Drink up me 'earties, Yo Ho!
Yo Ho, Yo Ho! A pirate's life for me.
Pixel Stuff
Sr. Member
****
Posts: 251



WWW
« Reply #11 on: May 05, 2006, 12:15 PM »

While you are working on a configuration panel, think about how to create two separate Podcasts on the same site. For example: If we were using only [[MODcast]] how would we differentiate between a video cast and an audio cast or two different audio casts.
Logged
Dr. Scotty Delicious
Coding Team
*
Posts: 1,172


Dr. of Fine Pirate Arts


WWW
« Reply #12 on: May 05, 2006, 04:15 PM »

While you are working on a configuration panel, think about how to create two separate Podcasts on the same site. For example: If we were using only [[MODcast]] how would we differentiate between a video cast and an audio cast or two different audio casts.


Hmmm?

Hadn't thought of that, as I just put this snippet together because I wanted to create a iTunes podcast of my music, so I only needed one feed.  The "dirCaster" script that I used for the basis of this snippet works ok for this. I can see how multiple would be totally useful.  If you have any ideas on how I could implement this, please post some very specific PHP code showing how to do this as I am basically a PHP noob (I just decided to start learning PHP about a month ago).  I am going to continue my current work on v0.3 as a single feed, but even as I am writing this I am coming up with ideas on how to implement that feature.  Thanks jbjones.  you got my gears turning here! Wink

-sD-
« Last Edit: May 05, 2006, 04:20 PM by ScottyDelicious » Logged

We pillage, we plunder, we rifle and loot. Drink up me 'earties, Yo Ho!
We kidnap and ravage and don't give a hoot. Drink up me 'earties, Yo Ho!
Yo Ho, Yo Ho! A pirate's life for me.
Dr. Scotty Delicious
Coding Team
*
Posts: 1,172


Dr. of Fine Pirate Arts


WWW
« Reply #13 on: May 05, 2006, 09:27 PM »

Ok, I have MODcastAdmin working to configure multiple pocasts/videocasts.  it now configures a user define feed for MODcast.  once configured, MODcast can be called as [[MODcast? &feed=`podcast1`]] or whatever it was you set your feed name to in MODcastAdmin.  I need to do a few more tests with it, and continue work with the *very* basic file upload.  It may end up being a total of 3 snippets, MODcast, MODcastAdmin (for uploading and deleteing), and MODcastConfig (for creating or editing the config file).  We will have to see how clever I can be.

-sD-
Logged

We pillage, we plunder, we rifle and loot. Drink up me 'earties, Yo Ho!
We kidnap and ravage and don't give a hoot. Drink up me 'earties, Yo Ho!
Yo Ho, Yo Ho! A pirate's life for me.
Pixel Stuff
Sr. Member
****
Posts: 251



WWW
« Reply #14 on: May 06, 2006, 02:50 AM »

Wow.  Those two posts were only like 5 hours apart.  Fast working there.
Logged
Pages: [1] 2 3 4   Go Up
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP

Copyright © 2005-2008 MODxCMS, All rights reserved. Contact Us
Styles by ziworks.com

Powered by SMF 1.1.4 | SMF © 2005, Simple Machines LLC

Valid XHTML 1.0! Valid CSS!