I'm experimenting with jPlayer as the solution for a site upgrade from D6 to D7. I've followed the README.txt to the best of my ability, though there were discrepancies:

- The jplayer configuration (at admin/config/media/jplayer) says it expects "jplayer.player.min.js" to be in the defined location.
- The file that comes from the jQuery.jPlayer.2.0.0.zip archive is named "jquery.jplayer.min.js"

Yet, even though I've tried both filenames, I still don't get a media player to render. Instead, I get a list of player controls in text. You can see this here: http://voicemarketingradio-com.cftvgy.org/node/1926#

I also configured the display field settings to appropriate values ("jPlayer - player", "Single" file), tried both HTML and Flash options; still no go.

Any help would be greatly appreciated!

Files: 
CommentFileSizeAuthor
#24 jplayer_base_path-707484-24.patch538 bytesjeffam

Comments

subscribe

Ok I've committed something to the dev branch that may solve this issue. The code is still in a state of flux. Try it out the tomorrow when the new code gets released or use GIT to get the latest.

Having the same issue - getting a list of player controls in text.

Not sure where to find the new code on GIT - couldn't find here: http://drupalcode.org/project/jplayer.git

(thanks for the module, btw)

Yeah, as of 3/22/2011 @ 11:39a, the most recent commit is from four days ago. jdelaune, your commit on 3/21 isn't showing.

Ah I must have forgotten to push my commit back! Will do so when I return to the office tomorrow.

Sweet. Thanks!

Component:User interface» Code
Category:support» bug

I just checked out the newest -dev as of this morning and this issue is still present as presented by the OP.

The problem is that the jplayer.js and jplayer.css files in the module folder are not being loaded. You can fix this by copying the contents of modules/jplayer/theme into your theme directory. Then load the .js and .css files by placing this code in your theme.info file:

  • stylesheets[screen][] =jplayer.css
  • scripts[] =jplayer.js

That worked for me.

I work with a group of developers and we just got it fixed, I'm running some tests now and it's working good. We can provide a patch tomorrow if the maintainer wants to, or if it doesn't explode on us until tomorrow! :-)

Also the little hack above does work well, and will get one moving until the module has been fixed! Thanks dougproctor!

Hmmm. I am getting some player UI elements, but they're still not working. I'm using Picture_Reloaded, a subtheme of AdaptiveTheme.

I copied all files from the latest "sites/all/modules/jplayer/theme" directory into my "sites/all/themes/pixture_reloaded" directory.

I took the two lines from post #8 and added them to the bottom of "pixture_reloaded.info" in the theme's directory.

I now see a basic rectangle graphic region with "play", "stop", progress slider, and volume control. You can see it at the same link from the OP (http://voicemarketingradio-com.cftvgy.org/node/1926#), but the controls don't seem to have any effect.

Thanks for all the attention to this!!!

FitPM, I just checked your source markup on that page. The CSS is loading fine but the .js file is still missing.

Try replacing scripts[] = jplayer/jplayer.js with scripts[] =jplayer.js in your .info file.

Pierre_M feel free to post a patch. I'm pretty busy with some tight deadlines at the moment and it's working fine for me this end so I don't have the time to debug as much as I would want to. I should be able to quickly test, patch and commit it if it works.

Cheers

Status:Active» Patch (to be ported)

Turns out it was an easy fix. I had to make sure that the way the js and css files were included could be easily overridden in the theme layer since in one of my projects I'm using a highly customised version of jPlayer which relies on this module as it's core (http://www.alphawebteam.com/sites/alphawebteam.com/files/custom-interfac...).

I just forgot to commit the change to the original template file from the one I was overriding. Fix should be pushed out to the dev release in just over an hour from now. Also brings Views support back up to scratch.

Let me know if there is anything else fishy or other improves you can think of.

Status:Patch (to be ported)» Fixed

Opps

Hey jdelaune, I would be happy to provide our patch, but I guess you don't need it anymore. I just got your latest version from GIT and it's working great! We are using your module on a new D7 site we are building, I'll be glad to test and report back any issues I find, and help you out along the way!

Cheers!

I guess I'm really close, but it's still not quite working.

@dougproctor, I tried your approach first, but I was a bit confused as my .info file already had "scripts[] =jplayer.js", so I went forward with jdelaune's patch. I appreciate your review very much, and wanna buy you a bev if we ever meet.

Now, after updating to the latest jplayer-7.x-2.x-dev @ 3/23/11-17:11, I'm getting the following error:

Warning: file_get_contents(/sites/all/libraries/jplayer/jquery.jplayer.min.js) [function.file-get-contents]: failed to open stream: No such file or directory in drupal_build_js_cache() (line 4749 of /home/voicemar/public_html/includes/common.inc).

I've confirmed that my "/sites/all/libraries/jplayer" directory _does_ include "jquery.jplayer.min.js". Can someone help me button this up?

Many thanks in advance.

FitPM are you running on a linux based system? Do you have a custom base directory e.g. is your site outside of a standard domain of say example.com/node/1

This site is served on Linux at Hot Drupal and does NOT have a custom base directory.

FitPM, I'm afraid I can't figure it out from here. Your site is loading the module's jplayer.js, but its not loading the library's .js file (as per your post #16).

This might be a dirty fix, but you can force the script to load in your html.tpl.php file:

<script type="text/javascript" src="<?php global $base_path; print $base_path ?>sites/all/libraries/jplayer/jquery.jplayer.min.js"></script>

newest dev version after a cache flush works fine. (Cache flush required because of alterations to .info when removing the workaround from above.)

I've some css issues to deal with but I don't believe that's an issue of this module. Evidentally the theme I'm using decorates ul's which wind up displaying in the player.

dougproctor, that worked, thanks! I'll see if I can wrap my mind around all these parts to figure where it's really going wrong. In the meantime, this gives me a heckuva lot more to work with.

Status:Fixed» Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

FitPM, I've had the exact same issue you're describing in #16. Changing jplayer.module's line 242 from

$path = base_path() . variable_get('jplayer_directory', 'sites/all/libraries/jplayer');
to
$path = variable_get('jplayer_directory', 'sites/all/libraries/jplayer');
fixed the issue. I don't think that base_path() should be there anyway because $path is Drupal path, not a URL.

Title:Player won't displayjplayer javascript won't load when js aggregation is turned on
Status:Closed (fixed)» Needs review
StatusFileSize
new538 bytes

I came across this issue when jplayer wouldn't load on my production site, which had js aggregation turned on. jamix's fix in comment #23 did the trick for me, and now jplayer works both with aggregation and without.

Here's a patch.

Status:Needs review» Reviewed & tested by the community

Hi,
Patch in #24 works fine for me (before, jplayer works only without js aggregation, now both with & without)
Thanks

Status:Reviewed & tested by the community» Fixed

I committed this patch in 8c7c2f1.

Status:Fixed» Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.