MediaDrop provides a robust frontend, but if it does not suit your needs you can easily revise it or even completely replace it, while still maintaining the benefits of MediaDrop’s admin interface.
A listing of the public-facing controller methods is below. See the mediadrop/config/routing.py file for information on the URLs that point to these methods.
Publicly Facing Media Controllers
Media actions – for both regular and podcast media
Post a comment from PostCommentForm.
Parameters: | slug – The media slug |
---|---|
Returns: | Redirect to view() page for media. |
Display the most recent 15 media.
Return type: | Dict |
---|---|
Returns: |
|
List media with pagination.
The media paginator may be accessed in the template with c.paginators.media, see webhelpers.paginate.Page.
Parameters: |
|
---|---|
Return type: | dict |
Returns: |
|
Redirect to a randomly selected media item.
Say ‘I like this’ for the given media.
Parameters: | slug – The media slug |
---|---|
Return type: | unicode |
Returns: | The new number of likes |
Serve a MediaFile binary.
Parameters: |
|
---|---|
Raises: |
|
Display a listing of all tags.
Display the media player, info and comments.
Parameters: |
|
---|---|
Rtype dict: | |
Returns: |
|
Podcast Series Controller
This handles episode collections, individual episodes are handled as regular media by mediadrop.controllers.media.
Serve the feed as RSS 2.0.
If feedburner_url is specified for this podcast, we redirect there if the useragent does not contain ‘feedburner’, as described here: http://www.google.com/support/feedburner/bin/answer.py?hl=en&answer=78464
Parameters: | feedburner_bypass – If true, the redirect to feedburner is disabled. |
---|---|
Return type: | Dict |
Returns: |
Renders: podcasts/feed.xml XML
Media Upload Controller
Display the upload form.
Return type: | Dict |
---|---|
Returns: |
|
Ajax form validation and/or submission.
This is the save handler for UploadForm.
When ajax is enabled this action is called for each field as the user fills them in. Although the entire form is validated, the JS only provides the value of one field at a time,
Parameters: | validate – A JSON list of field names to check for validation | ||||||||
---|---|---|---|---|---|---|---|---|---|
Parma **kwargs: | One or more form field values. | ||||||||
Return type: | JSON dict | ||||||||
Returns: |
|
Sitemaps Controller
Sitemap generation
Serve the crossdomain XML file manually if static_files is disabled.
If someone forgets to add this Alias we might as well serve this file for them and save everyone the trouble. This only works when MediaDrop is served out of the root of a domain and if Cooliris is enabled.
Generate a media rss (mRSS) feed of the sites featured media.
Generate a sitemap which contains googles Video Sitemap information.
This action may return a <sitemapindex> or a <urlset>, depending on how many media items are in the database, and the values of the page and limit params.
Parameters: |
|
---|
Generate a media rss (mRSS) feed of all the sites media.
Generate a media rss (mRSS) feed of all the sites media.