Hello
I've updated from alpha2 to beta2 for drupal 6.x, but am unable to view any video on my website, am getting the error "200 stream not found....." but the videos (flvs) are present on my server, anyone can help?

CommentFileSizeAuthor
#13 playlist.patch759 bytespsmx
#4 video-1061092.patch1.47 KBtacituseu

Comments

lordrt21’s picture

Actually found that my videos are stored in a subfolder, files/videos, while flowplayer is looking in onle files, any settings where I can change this to point to the videos subfolder?

hypertext200’s picture

Please check the field settings, there is no big difference with ALPHA2 and BETA2, so small debug will work

lordrt21’s picture

I've checked the settings, everything seems normal, but still not able to access my videos. Am using flowplayer to play along with swftools, and for now am using the swftools input filter to display the videos, but still using flowplayer, while using the video module itself is only loading the flowplayer but then giving the 200 stream not found error

tacituseu’s picture

StatusFileSize
new1.47 KB

When using video thumbnails with swftools/flowplayer3 there is a problem with a way it handles image path in flowplayer3_swftools_flashvars() (original comments):

  // If an image was supplied to be the splash then put this first in the list
  // This code doesn't seem to be working - the player objects to { url: '' }
  if (isset($vars->othervars['image'])) {
    $playlist[] = array(
      // Get url, checking for file existence, and using a relative url if possible.
      'url' => swftools_get_media_url(swftools_get_media_path() . $vars->othervars['image']),
      'autoPlay' => 'true',
    );
  }

and theme_video_flv()

      'othervars' => array(
        //@todo: swftools bug, can't enable this until they fix their pathing for the images.
        'image' => $video->thumbnail->swfthumb,
      ), 

swftools_get_media_path() is equivalent to file_directory_path() and path supplied in $video->thumbnail->swfthumb already contains it so you will end up with path to your files directory prepended twice (eg. 'sites/default/files/sites/default/files/video_thumbs/36/video.png') which will result in mentioned '200' error, alternatively if there is no thumbnail for this video and you don't have default thumbnail set $video->thumbnail->swfthumb contains empty string which will result in player getting path to files directory (eg. 'sites/default/files/').

It will work with swftools 2.5, haven't tried 3.0-beta4.

tacituseu’s picture

Version: 6.x-4.2-beta2 » 6.x-4.x-dev
Component: Miscellaneous » Code
Status: Active » Needs review
versalu’s picture

I am using "video" and "flowplayer" module and have the same problem with the URL but i have not activate de thumnail or convertion option.

can i solve this with the same patch?

tacituseu’s picture

It works only when you have 'FLV Flash Players'/'SWF Tools' selected at 'admin/settings/video/players', combined with 'Default player' set to 'FlowPlayer 3' at 'admin/settings/swftools/handling', it doesn't affect codepath for standalone flowplayer.module.

tacituseu’s picture

Status: Needs review » Needs work

Found this in class video_helper::thumbnail_object():

    //swftools appends sites/default/files to the front of our path...
    //@todo Is this a setting?  Need to figure this out.
    $thumbnail->swfthumb = $thumbnail->filepath; 

I assume this would be a proper place to patch it, consider previous patch more as a workaround.

lordrt21’s picture

thanks, but how do I apply the patch? need to copy code to a specific file?
Also the videos am uploading using CCK+FileField (created a field in the node to accept video uploads) are already in flv format, so no conversion and no thumbnails being generated.

lordrt21’s picture

so far, without patch, when i uploaded a video, it goes to the files/videos folder, however the flowplayer is giving the error as it is looking only in the files folder, not going to the videos one at all...

tacituseu’s picture

See http://drupal.org/patch/apply or by hand as it has only one hunk.
Attaching generated embed/object code might help in diagnosing your issue (specifically flashvars).

lordrt21’s picture

I got a workaround by using this module and disabling video module: http://drupal.org/project/videofield
but still would like to know why video module is not playing as it should

psmx’s picture

StatusFileSize
new759 bytes

I was also looking for a fix of this issue using video 6.x.4.2-beta2 and usind standalone flowplayer 6.x.1.0 -beta1.

I fixed it by changing line 191 in video_formatter.inc from

if (!$video->autoplay && $video->thumbnail->url) {

to

 if (!$video->autoplay && $video->thumbnail->url && file_exists($video->thumbnail->url)) {

This renders the video normally and shows a thumbnail which surprisingly always worked for me, even before this patch was submitted to HEAD.

Seems that this patch caused my problems: http://drupal.org/node/973950

ñull’s picture

Issue tags: +bug workaround

The problem is really simple. How to make a patch for it is another. What the video module needs to do is strip the filesystem folder part of its relative file paths.

When in includes/video_helper.inco you uncomment the

//    echo '<pre>';
//    print_r($video);
//    die();

and look at a video node, then you will see a dump that shows that the video module has all the path with the file system path prepended: sites/all/files/.... So it is not only a problem of the thumbnails!

swftools however by default expects its media files in http://yourdomain.com/sites/all/files/....

This means that that video module when working with swftools should strip all sites/all/files from the beginning of the file paths. Since in Drupal all files are uploaded in the filesystem path I would say that swftools is doing it right and video is doing it wrong. I will therefore not try to roll out a patch for this but I will show you a simple workaround.

What you need to do is change the default media path of swfttools, BUT YOU CAN ONLY DO THIS ON A NEW SITE. On existing sites you wll break all swftools related media paths.

You go to the settings.php of your site, you either use the existing $conf = array() or you create one with:

'swftools_media_url' => 'http://'.$_SERVER['HTTP_HOST'], // No trailing slashes!

If your drupal is not directly under the domain but in a folder then you need to do this :

'swftools_media_url' => 'http://'.$_SERVER['HTTP_HOST'].'/myfolder',

This will make swftools look in your document root in stead of sites/all/files or whatever you have in the file system setting. Better would be when somebody writes a patch though, because this setting is meant for sites that have their media on another server and it is only an option for new sites that use swf exclusively for the video module. I think that video module should just work with swftools out of the box, because it claims compatibility and this is clearly a sign that it isn't.

fang27’s picture

In my case, the URL that flowplayer is trying to pick up is the original, not the converted file. Any idea where to make a change for that?

John Carbone’s picture

Tweak in #13 at least got my videos playing in flowplayer again. Not sure about the thumbnails yet though.

Jorrit’s picture

Status: Needs work » Postponed (maintainer needs more info)

Please test again using the latest version.

Jorrit’s picture

Status: Postponed (maintainer needs more info) » Closed (cannot reproduce)

Closed because of lack of response.