how can i get the real video file path?

IZAPSETTINGS->playerPath."?movie=".$this->videosrc . $extraOptions ."&volume=30&autoload=on&autoplay=on&vTitle=".$this->title."&showTitle=yes' >
i think the $this->videosrc is give the player path,but it is not the flv or mp4 file real path, i want give the video player the real path.
i want try,but it is not work ,can anybody tell me how to add real path to the video play
thanks very much

  • it is about izap video code

  • If you have the video entity assigned to the $video variable (your job to do that depending on what you actually have in mind...) you can get the video url with

    $url = $video->videosrc

    The full path to the video file can be retrieved with

    $user_data_dir_location = new \Elgg\EntityDirLocator($video->owner_guid);
    $videopath = elgg_get_config('dataroot') . $user_data_dir_location . $video->videofile;
  • thank you iionly,but how to use it? i try every way to instead the $this->videosrc, it can not work.

    can you help me please?

  • I don't know what you want to achieve, so I don't know how to help...

    The only place $this->videosrc is used is in mod/izap_videos/lib/izap_videos.php in the getPlayer() function. And the usage here is the way it has to be. You can't provide a file path to the video file. You need to provide the url (for the offserver videos for example from youtube anyway but also for onserver videos - iZAP Videos deals with resolving the url to provide the corresponding video file).

    If you change anything here, it's very likely that you would also have to modify other parts of the code for the plugin still to work. And not knowing what you have in mind I can't even tell you if this would make any sense or if you would be able to achieve your goal in another way better/easier/at all.

  • it is about support mp4 and all html5 file for the mobile device.

    this $this->videosrc give me path is,it is can not for seeking and streaming, if i replaced the real and direct path is

    you can see my website

    what is happened,


    1. Server:
      Apache/2.4.10 (Win32) OpenSSL/0.9.8zb mod_fcgid/2.3.9 mod_h264_streaming/2.2.7
    2. Timing-Allow-Origin:
    3. X-Mod-H264-Streaming:
    if i still use that $this->videosrc transport to

    me,that is

    1. status:
    2. timing-allow-origin:
    3. x-powered-by:
    i need the X-Mod-H264-Streaming work,it is real video on the site working,i get this trouble for many days


  • You seem to be already much further with getting html5 video support implemented in iZAP Videos for uploaded videos than I am. It's on my ToDo list for quite some time already but I never had time to work on it up to now. Sorry for that... But I don't think I can provide you with any useful advice at the moment.

    I would have said that it might be necessary to switch to the new file serve API of Elgg for getting it to work. But as you are still on Elgg 1.8 this isn't an option for you. In the end you might need to alter the value saved in videosrc already when a video is uploaded to suit your needs. And you would likely need to update the value for existing video entries.

    The point is, that it's a matter that's not trivial and it will take some time to get it working (at least I think you need some time and therefore I haven't started with it so far...). Maybe you could start "at the end": what's the code and filepath or url necessary to play the video. And then go backwards from there and modify the corresponding classes, functions and object data to save and deal with the necessary data on uploading, converting, saving and what else necessary with a video entry. Last but not least deal with updating existing video entries.

    If you have some code to share, I would be happy about seeing what you have done so far. While I don't see me working on it anytime soon, it might still help me once I can work on it. You could send it to if you want to.

  • hi iionly,

    i haved used the jwplayer flowplay and videojs everyone is ok ,even just this 

    <source src=\"$this->videosrc\">

    to replace

    <video width='".$width."' height='".$height."' id='mp4Player'>
    <param name='allowFullScreen' value='true'>
    <param name='allowScriptAccess' value='always'>
    <param name='movie' value='".$this->IZAPSETTINGS->playerPath."?movie=".$this->videosrc . $extraOptions ."&volume=30&autoload=on&autoplay=off&vTitle=".$this->title."&showTitle=yes' >
    <embed src='".$this->IZAPSETTINGS->playerPath."?movie=".$this->videosrc . $extraOptions ."&volume=30&autoload=on&autoplay=off&vTitle=".$this->title."&showTitle=yes' width='".$width."' height='".$height."' allowFullScreen='true' type='application/x-shockwave-flash' allowScriptAccess='always' wmode='transparent'>

    if load  video.js is better like

    <head> <link href="" rel="stylesheet"> <!-- If you'd like to support IE8 --> <script src=""></script> </head>

    i do this at engine/lib/views.php
    elgg_register_js('videojs', ';, 'head');
  • i select elgg1.8 for testing because too many plugins for choice:)),thank you iionly

Performance and Scalability

Performance and Scalability

If you've got a need for speed, this group is for you.