Active
Project:
jQuery Media
Version:
6.x-1.4-beta1
Component:
Miscellaneous
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
12 Mar 2009 at 21:52 UTC
Updated:
11 Jan 2011 at 10:17 UTC
Jump to comment: Most recent file
Comments
Comment #1
-Anti- commentedBump.
I've got a separate mp3 player and video player (both JW players).
I need to tell the mp3player to be 400x30px and the video player to be 600x400px.
But I don't see how to send separate flashvars or params to the players from the admin page?
There seems to be only *one* default setting for *both* players?
If that's the case, I don't understand the point of specifying the flv and mp3 players separately?
Surely for two players it makes sense to be able to give therm different flashvars and params?
Can anyone assist? I'm quite desperate to get this working.
BTW, I'm using FCKEditor: the user just links to the uploaded mp3 or flv file, and then
adds 'media' as the css class, which jquerymedia then embeds automatically.
It is too much to ask my users (who are school children) to include vars in the FCKeditor body,
and anyway, I don't think FCKeditor would allow that.
Thanks.
Comment #2
-Anti- commentedbumping this.
I still don't see the point in specifying a separate mp3 player and video player
if they both have to use the same dimensions and share the same flashvars.
Thanks.
Comment #3
agileware commentedI have done this before by doing the following:
1. I have two file fields called audio_file and video_file (this is just as an example you can have any any amount of fields with any names)
2. In your template.php file override the theme_filefield function so that your audio and video fields have different css classes.
For example (again you might want to make this different depending on how you set up your fields and if you have more unrelated file fields or use a different method of distinguishing between the file types):
3. In a nodeapi function somewhere add something like this:
4. In the settings screen for jquery_media, make sure extra settings -> classes -> media -> auto-invoke media class is not checked (your nodeapi takes care of the invoking).
From memory that was all I did and it worked.
This will make it so that anything that is in one of your file fields that has a mime type starting with audio will be rendereed in the different sized media player and everything else will use your normal size settings.
Comment #4
agileware commentedActually, my solution was done for a Drupal 5 website. But the solution should be pretty similar in 6.
Comment #5
agileware commentedAlso, if you don't already have it installed you will need to jq module (http://drupal.org/project/jq) for this solution to work as it provides the jq_add function.
Comment #6
agileware commentedhttp://drupal.org/node/407510 is a duplicate of this issue.
Comment #7
-Anti- commentedThanks for your reply.
However, I'm not using cck fields to add videos.
The user just links to a file they've uploaded via IMCE.
The link is created in FCKeditor. They type 'media' into the stylesheet field.
Jquerymedia 'sniffs' the class in the link and embeds the file.
The manual solution to this is to pass a dimension to the mp3 player
in the FCK 'stylesheet' field, like this (requires the jquery metadata plugin):
media {height:40}
However, this only works if you allow the user full html input format.
For some reason, Drupal strips out the class leaving only: 40}
So, now I'm stuck with playing mp3s in a video player, taking up 640x400.
Comment #8
XerraX commentedthere really should be options for different content types and file formats.
Do a search for "size" in the issue query and you will find a bunch of relating problems.
Hope this got solved soon, because i really like this module :(
Comment #9
armyofda12mnkeys commentedAnyone figure make a setting for this yet? subscribing...
Comment #10
armyofda12mnkeys commentedI made a ghetto solution (using default jmedia.media.js that comes with module so @version: 0.81 (06/05/2008)):
and then set that opts.original_src to original src, so you have the filename to look at, I also added some code to choose the correct player based on if mp3 or flv... before it sets the flashvars incorrectly for 1px Out Player as mentioned in this thread http://drupal.org/node/244524#comment-3931340:
Think you can pass separate height/width now on a settings page to pass to that audio width/height part, but I dont have the time to set.
Comment #11
armyofda12mnkeys commentedAttached is the current file I using (rename minus the .txt):