Hi Travis, or anyone else successfully OSMing in D7……
I'm desperately trying to get Mediafront OSM player to work in Drupal 7 but not having much luck with it…..
Have tried a few different builds and each time can't get the player to play a video in a single node.
Installed:
Mediafront 7.x-1.x-dev (11/9/2010)
Preset 7.x 1.x dev (11/9/2010)
Drupal 7 dev (11/9/2010)
with the following procedures:
-Build Drupal with above modules)
-Create OSM preset
-Create a Content Type with the following fields and settings:
- Video (LABEL); field_video(NAME); Media Player (FIELD); Media Player (WIDGET)
- Video Upload (LABEL); field_videoupload (NAME); File (FIELD); File (WIDGET)
- Set "Video" field(Media Player) at the top of the content type followed by "Video Upload". (I also have Image Upload)
Everytime I set this up in D7, the player shows up but does not load any video. Same setup works fine in D6 . I feel like I'm missing something simple here but can't quite figure it out.
Live site in question:
http://westwellproductions.com/WW4/node/1
Did anyone go through a similar thing?
Thanks!
Comments
Comment #1
travist commentedI have done some work on the Drupal 7 version tonight. Please retest with the latest version available tomorrow and let me know if you have better luck.
One thing that you will need to do is add the "Node: Nid" as a field for your view. That is one difference between the Drupal 6 and Drupal 7 views that I was not able to get around.
Let me know if this works for you.
Thanks,
Travis.
Comment #2
musee.informatique commentedI have the same issue even if I create a new view with the media front field, the video upload field and adding a field with the node nid
I obtain a view with the osm player and under a file view that lists all video uploaded on the current item
I think I missed something ^^
Comment #3
Blooniverse commented... same (player not loading videos) here. My system:
The strange thing is, that if I am logged in as user1 the player at least seems to pick up the video and put it into the playlist. Anonymous users cannot even see playlist thumbnails.
By the way, since the most current version of 'MediaFront' (2011-Jan-10) I even get following error messages:
This could become a great module! Keep going & thank you for the bug fixing.
Comment #4
Blooniverse commented... in the case of a CCK configuration, 'MediaFront' doesn't seem to know the URL of the video! When I configure, for test purposes, 'url to/of file' under 'format' ("manage display") instead of the format 'general file', the node output doesn't show anything. So it seems that there is just no known video file URL!
Comment #5
musee.informatique commentedI think I found it !
in mediafront.module, in the _mediafront_get_field function, you're trying to find media files and covers to show in the player but I think there's some troubles here
First, the video upload field must be named field_mediafront_media (I would have prefer to have a new option in the mediafront module in order to fill it with the name of the field I want to be used by the osm player)
And another problem is that in this function, you're trying to get an array named "und" but here is a dump of field_mediafront_media (obtained by var_dump($node->{'field_mediafront_media'}); in the mediafront_playlist_node function ):
array(1) {
["fr"]=> array(2) {
[0]=> array(11) {
["fid"]=> string(2) "42"
["display"]=> string(1) "1"
["description"]=> string(0) ""
["uid"]=> string(1) "1"
["filename"]=> string(33) "Buy_a_Mac_15_Ads_in_1_Pack_HQ.flv"
["uri"]=> string(44) "public://Buy_a_Mac_15_Ads_in_1_Pack_HQ_1.flv"
["filemime"]=> string(11) "video/x-flv"
["filesize"]=> string(8) "16342288"
["status"]=> string(1) "1"
["timestamp"]=> string(10) "1294747040"
["rdf_mapping"]=> array(0) { }
}
[1]=> array(11) {
["fid"]=> string(2) "43"
["display"]=> string(1) "1"
["description"]=> string(0) ""
["uid"]=> string(1) "1"
["filename"]=> string(17) "Mac_VS_PC_Pub.flv"
["uri"]=> string(28) "public://Mac_VS_PC_Pub_1.flv"
["filemime"]=> string(11) "video/x-flv"
["filesize"]=> string(8) "25438113"
["status"]=> string(1) "1"
["timestamp"]=> string(10) "1294747040"
["rdf_mapping"]=> array(0) { }
}
}
}
I think fr is my language (french) but I really don't know what does "und" stands for.
I also have another problem, if I replace "und" by "fr", the osm player runs fine but only have one video (but I have 2 of them as you can see in my dump) and the player has a cover picture he takes in a gallery field and that has nothing to do here
does it helps ?
Comment #6
Blooniverse commented@musee.informatique: Following tutorial doesn't recommend the usage of a field with the name 'field_mediafront_media' as a video upload field at all.
@Everyone: Instead, the mentioned tutorial recommends an impossible field name called 'Video Upload', which is really impossible due to the blank space in between the two words! Drupal doesn't accept this, obviously.
http://www.mediafront.org/documentation/drupalmediafront-osm-cms-integra...
Comment #7
marshallexcavating commentedOn new drupal 7.0 install I had to:
1. install MediaFront 7.x-1.x-dev
2. install Preset 7.x-1.x-rev
3. install services 7.x-3.0-rc1
Then I followed the set up instruction and the player works only for mp4 files; well it only plays the .mp4 file sound no video. I tested mp4, mpg, flv, mov, and m4v files withe no luck.
I also found that panels-7.x-3.0-alpha1 module was causing problems so I uninstall it to get player presets to work. The good news is that mp4 file sound works with this simple to set up configuration.
I hope this is helpful.
Comment #8
musee.informatique commented@the_phi: the tutorial can say what it wants, I've looked directly in the source code of this module and there's some hard coded variables
I think I'll wait for the final release of this module
with my tweak of the dev release, I can play a flv file from my file field. I thought I was on the good way.....
Comment #9
Blooniverse commentedThanks, @musee.informatique! In this case you must be right (excuse mon travail superciel)!
And in deed, in the file 'mediafront.module' I can see/find 'field_mediafront_media':
Luckily this seems to be the only place with this hard coded variable!
Comment #10
Blooniverse commented... wait, the PHP code from line number 568 onwards looks for other fields as well:
Dear maintainer @travist, you are the master of this module: Could you please explain how this is supposed to work?
Comment #11
marshallexcavating commentedI have noticed that the "mediafront.module" has a closing php tag ?>on line 696. I think this can cause some problems. I have removed the tag from my install with no effect seen.
Comment #12
travist commentedI have been testing in Drupal 7 and it works just fine with the filefield and Media module. Please try those and let me know if you have better luck.
Comment #13
musee.informatique commentedwhich name for the file field ?
Comment #14
marshallexcavating commented@Travist comment #12. I have tested the following two configurations with the same out come; .mp4 auto no video and all other file extensions wont work.
Setup/configuration #1:
With the following modules enabled on drupal 7.0:
MediaFront module: version = "7.x-1.0-rc3"
Preset module: version = "7.x-1.x-dev"
I created:
cck field "file" : file_myname1
cck field "Media Player": file_myname2
for #1: I can only get the sound/auto to play in a .mp4 file. Otherwise player shows up with spinning wheel for all other file types.
Setup/configuration #2:
With the following modules enabled on drupal 7.0:
MediaFront module: version = "7.x-1.0-rc3"
Preset module: version = "7.x-1.x-dev"
Media module: version = "7.x-1.0-beta3"
Styles module: version = "7.x-2.0-alpha5"
I created:
cck field "Multimedia asset" : file_myname1
cck field "Media Player": file_myname2
I get the same out come .mp4 sound/auto no video and all other file types shows spinning wheel.
I hope this a helpful description of what I think is a correct configuration.
Comment #15
marshallexcavating commentedI have noticed that if the player is in a node that is trimmed the player only shows spinning wheel. note if publishing video content to front page the front page content is trimed content. With that .ogv and .flv files work fine for me; .mp4 onaly auto no video.
I hope this a helpful
Comment #16
Blooniverse commented... re-opening the issue. I'm using the version 'MediaFront 7.x-1.x-dev (2011-Jan-28)' in the meantime, but the player still only displays videos for logged in users -- not for anonymous guests. Why is that? There are no explicit settings on the permissions page available to be activated. Thank you for checking.
The other thing is, that I need to drag the timeline button in order to start the video. A click on the play button alone doesn't function. Hmm ...
Comment #17
mfbThe media player seems to only work for fields named "field_mediafront_media". That seems like a major limitation. There is some code to look for other fields:
but this doesn't seem to do anything, as the $node object does not support iteration.
Comment #18
travist commentedmfb,
This should work for other cck fields and it shouldn't matter the name of the field. There is a special field called field_mediafront_media that I use when I wish to load media into the player from a text field ( URL ). That is the only reason for that field.
I will investigate nonetheless and make sure that the latest DEV is stable, but typically the DEV versions are for testing purposes only.
Thanks,
Travis.
Comment #19
travist commentedAlright... I just investigated this and really think this is an issue with the Services module. If you go into your preset, and under Other Settings, make sure that you have AJAX only selected as the communciation protocol. That will fix this.
I also fixed future versions of this module to always use JSON communication so that the Services module never messes this up again.
Thanks.
Travis.
Comment #20
Elder Brother commentedSorry to re-open, but I think a problem exists irrespective of Services.
I have a drupal 7 (7.0 core) site using mediafront as a field to display ogv, flv and mp4 on a node page successfully, Communication Protocol in preset set to Ajax. Mediafront is v7.x-1.0-rc8.
I am currently building a 7.2 core site, and have been unable to get any video to load in the player, with the same setup. I've tried both the current dev (27th June) and 7.x-1.0-rc9 versions. I've set Json in the preset (for the rc9 version, option not visible in the dev version). All preset settings are identical to those in the previous site.
Fields pretty much as per Bnishii's opening post-
File field of 'field_video_upload' with MediaFront: Media Settings ->Media Type set to 'Media Content' with allowed file extensions of mp4, mov, flv, m4v, mpg, mpeg, ogg, ogv, mp3, oga. Number of values is set to 3 to allow flv, mp4 and orv to be uploaded.
Image field of 'Image Upload' with MediaFront: Image Settings ->Media Preview Image and Media Thumbnail Image both set to 'original image' for now.
Mediaplayer field of 'field_video' with display format picking up my preset.
Media player appear on node page with all page elements visible (i.e. the volume control and loading gif are permanently visible), and no poster image nor any of the video formats load.
Of the other modules I have installed that differ from the first site where mediafront works, I can't see there being a conflict, but listed here anyway -
User Reference
File Entity
Media
Media Internet Sources
Disqus
Entity tokens
Image caption filter
Libraries
File Styles
Styles
Styles UI
jCarousel
Eva
Views Slideshow
Views Slideshow: Cycle
Comment #21
travist commentedYou wouldn't happen to have a live URL I could look at would you? This would be very helpful for me to get to the bottom of this.
Thanks,
Travis.
Comment #22
Elder Brother commentedI'll post when I put the site live (hopefully this week), currently working from MAMP.
Comment #23
mfbre: #19 hmm I didn't even have Services module installed (it's not mentioned as a dependency in mediafront.info or README.txt) will have to give this module another try when I have a chance..
Comment #24
travist commentedmfb,
Yeah, for now I disabled it even trying to use Services since that was only used to try and incorporate voting within the player ( which isn't a very high use case ). If you download the latest 7.x version, it should work no problems. I just tried a fresh install with Media module + MediaFront and it works great. I will be releasing a stable version this week that I am confident works so would definitely like you to give it another shot after that point.
Thanks,
Travis.
Comment #25
Elder Brother commentedI've just solved the problem with my config - an undefined function in the JCarousel module initiation code was causing both Mediafront and Colorbox to fail.
Seems obvious now, but for anyone else, do check Firebug console for any errors that might be messing with other Jquery dependent modules such as this one.
Thanks for the response Travis!
Comment #26
enjoylife commented