ZenPhoto + FlowPlayer + iPhone/iPad video

Over at FlowPlayer the page for 3.2.3 makes the claim that it has support for iPhones and iPads.

http://flowplayer.org/3.2/3/

Version 3.2.3 also seems to be the same version that the latest release of ZenPhoto includes. It appears that the way to get it to work simply has to do with the way you format your HTML. But playing of mp4s isn't working.

Given the information above could someone help me with some tweak I could make to the source or html that would enable this iPhone "support" with the default theme?

Comments

  • acrylian Administrator, Developer
    You will probably have to modify the flowplayer3 plugin.
  • I'm also very interested in adding support for ipads and iphones. Did you or somebody else already find out how we can do this? I looked at the information at the Flowplayer site but it's all very confusing for me and I don't know where to start.....
  • acrylian Administrator, Developer
    Flowplayer supports iPad and iPhone even without this plugin. This support comes from the fallback embedding features that are included in the flowplayer.js script. This plugin offers following additional features and benefits, that are not included in the default fallback of flowplayer.js:
    http://flowplayer.org/plugins/javascript/ipad.html
  • I changed flowplayer3.php a bit so it can show video and audio on an ipad. I installed flowplayer.ipad-3.2.1.js in the flowplayer3 folder and I added the following line to flowplayer3.php:

    <script type="text/javascript" src="<?php echo WEBPATH. '/' .ZENFOLDER. '/'.PLUGIN_FOLDER; ?>/flowplayer3/flowplayer.ipad-3.2.1.js"></script>

    I also added .ipad()to the flowplayer call in flowplayer3.php.

    More information can be found at:
    http://flowplayer.org/plugins/javascript/ipad.html
  • Morty Member
    Hey i have been looking into on how to replace the flowplayer version in the flowplayer plugin for a commercial one.

    but i can't seem to find any info regarding using another player
    without loosing the zenphoto plugin and going with a standalone player.
    it seems to be a relatively simple option to include.

    any thoughts on this would be greatly appreciated

    Morty
  • acrylian Administrator, Developer
    As far as I there is no real technical difference between the GPL and the commerical version. You would have to replace the included one with yours. Of course you have to do it again on every update. Look at the plugin files.

    Seems you also need to add the product key:
    http://flowplayer.org/demos/commercial/index.html

    This means you have to modify the plugin directly. Best you make a custom plugin of it.
  • Morty Member
    okay, thank you!

    just another thing...

    the function in which image urls are store in the
    database and update automatically as soon as you
    upload a new album using FTP.

    which part of the php script is that, if more then more section??

    anyway, love the script and the zenphoto flexibility!!
    cheeeers.
    Morty
  • acrylian Administrator, Developer
    That is functionality of the core classes. Why do you need to know that specifially?
  • Morty Member
    I am working on a small upload script as part of my exams
    and had a hard time finding information on how to create dynamically upon upload in both a user form as well as ftp.

    Thanks
  • acrylian Administrator, Developer
    I suggest to look at the admin files for upload then. Generally I would suggest to read the object model tutorial if you haven't already.
  • Morty Member
    Okay i will.

    thanks again, much appreciated
  • I'm so glad I saw this thread. It looks like marjolein figured it out but I'm confused by what he/she wrote:
    I also added .ipad()to the flowplayer call in flowplayer3.php.
    Even with the documentation I don't know where to put this code.
    Also, do I have to change any plugin settings, i.e., disable 'Autoplay' and/or 'Splash image'?
    If I don't get my videos working on an iPad my wife will stare at me with disappointing eyes. Heheh.. Any help is much appreciated.
  • acrylian Administrator, Developer
    You need to make your own custom flowplayer plugin by modifying the existing one.

    As said before FLowplayer will play even without on iDevices if the correct movie format is used (mp4 that is).
  • Thanks but mp4 doesn't do the trick, I still get that prompt to "Install latest Flash player.." I tried uploading an m4v but zenphoto doesn't seem to read it. Not that I'm complaining... zenphoto is an absolutely outstanding and brilliant cms. I would cry if I had to live without it.
    I was kinda hoping someone would know what line to put that bit of code, as I'm not adept enough to create my own plugin.
  • acrylian Administrator, Developer
    The flowplayer site says it would play directly by default. I don't have any iDevices so I neiter can help nor test anything (although I am Mac user otherwise).

    I have put adding that iPad plugin to the official plugin on my list for Zenphoto 1.4.2 (scheduled December 1st). It will probably sometime before that in the developlement nightly build.

    Zenphoto does not recognize .m4v currently, only the generic .mp4. It is planned to change that for 1.4.2 as well. There are also plans to make a proper jPlayer (jplayer.org) plugin (There is a 3rd party one only for audio playlists).
  • Acrylian, you guys have an amazing product here. I'll be looking forward to the next update. In the meantime I'll keep tinkering along. Thanks for your help.
  • Just thought I'd pop some info in this thread based on my own experiences.

    As Marjolein stated above,there are some tweaks you can make to Flowplayer to get it to play mp4 videos embedded in ZenPhoto on the iPad instead of going full screen (on the iPhone they will only play full screen).

    Download and copy flowplayer.ipad-3.2.2.min.js to your /zp-core/zp-extensions/flowplayer directory.

    Now you need to make two changes to flowplayer3.php:

    Add the following line underneath the similar ones within the flowplayer2JS function:

    <script type="text/javascript" src="<?php echo WEBPATH . '/' . ZENFOLDER . '/'.PLUGIN_FOLDER; ?>/flowplayer3/flowplayer.ipad-3.2.2.min.js"></script>

    Towards the end of flowplayer3.php you will see the following lines:

    }
    $playerconfigadd .= '
    }
    });
    // ]]> -->
    </script>';
    $playerconfig = $playerconfig.$playerconfigadd;
    return $playerconfig;
    }

    Change this line:

    });

    to

    }).ipad();

    This will get embedded playback working correctly.

    Also, there seems to be a bug in the iPad's iOS that doesn't affect the iPhone. All my attempts at playing mp4 videos using Flowplayer when ZenPhoto is running over HTTPS result in Safari saying "This movie could not be played". Other browsers like iCab don't have this problem, but apparently Safari has a bug that prevents movies being streamed over HTTPS unless your web server has an intermediate certificate installed. This took me ages to discover so hopefully I've saved a couple of headaches here. You'll need to run ZenPhoto over HTTP or install the correct certificate for the videos to play.

    More info: http://stackoverflow.com/questions/4660189/cannot-view-quicktime-movies-over-https-in-safari-or-uiwebview

    Gilbo
  • acrylian Administrator, Developer
    Thanks, that will be in Zenphoto 1.4.2.
Sign In or Register to comment.