[Elgg 1.8-1.12 & 2.X & 3.X: iZAP Videos - revised edition by iionly] v2.0.1

Release Notes

  • Fixed Fatal error showing up on Elgg 2.2 due to incompatible declaration of IzapVideos::getIcon() (already declared in Elgg\\EntityIcon::getIcon($size, $type = 'icon')). As this method is not used apparently at the moment the fix consists of commenting out the function...
  • Hi, iionly.

    Your plugin shows two different values of upload_max_filesize. On "Server analysis"-Tab is value from php.ini. On the "Upload video"-Site the value is from .htaccess. It is wrong because .htaccess not used on my server.


  • @Johi The size shown on the server analysis page in the plugin settings should show the value of the php variable upload_max_filesize either from php.ini or .htaccess (when used will override the value set in php.ini). This value is the filesize limit of php that you must stay below.

    The size shown on the upload video form is the filesize limit set in iZAP Videos's plugin settings. This value is only for video files uploaded with iZAP Videos. This separate limit allows you to define a limit for the video uploads that can differ from the general upload_max_filesize php variable (but can't be larger than this limit). If the video files limit is too small for your requirements just change it in iZAP Videos plugin settings.

  • Thank you, all right. But

    but can't be larger than this limit

    Yes, we can!

    Sorry, my fault. ;-)

    Yes, it can!

    from the "Server analysis"-site: upload_max_filesize 2MB

    from the "Upload video"-site: Video file (maximum allowed file size is 5 MB)

    best regards

  • Default size set in .htaccess by Elgg is 5 MB for upload_max_filesize. Default size set by iZAP Videos is 5 MB (that's means if you don't change the limit in iZAP Videos it will be 5 MB that is displayed in the upload form and you also won't be able to upload any larger videos).

    I've just looked again in the code to make sure I don't say anything wrong. iZAP Videos does NOT override the limit set either in .htaccess or in php.ini. While you can set a larger limit in the iZAP Videos settings page this will still result in the upload to fail if the video file is larger than the limit set in .htaccess or php.ini for upload_max_filesize (I guess it would be better to check this when saving the settings and I might add such a check in a new iZAP Videos plugin release).

    The 2 MB limit you see on the server analysis page is very likely the limit set in php.ini on your server if you don't use .htaccess. And if you don't increase the limit in php.ini the upload of videos larger than 2 MB will fail (at least I guess so).

  • And if you don't increase the limit in php.ini the upload of videos larger than 2 MB will fail (at least I guess so).

    It's exactly what happened me.

    (I guess it would be better to check this when saving the settings and I might add such a check in a new iZAP Videos plugin release).

    That would be very nice.

    best regards

  • hi im trying to use your izap video and when adding a youtube video i continue to get error that it could not contact the site i have created an api key and added in admin does my site need to run in ssl? do i still need izaps bridge plugin? is there some way to turn on a log so i can see whats going on behind the scenes? i have tried for hours and can not get it to work unfortunately no video for elgg would kill it for me any help would be appreciated 

    thanks fred

  • @doughboy The izap_bridge plugin is not needed. SSL is not mandatory, i.e. you can use izap_videos both with and without SSL.

    My guess is that the Google API key might not be correctly configured yet. You can try adding an off-server video from Dailymotion and/or Vimeo. If this works and only adding videos from Youtube fails, this is an indication that the API key is the cause.

    You need not only create a Google API key. You also need to enable the Youtube v3 API for the API key. Also, don't add any domain or IP restrictions to the API key. The API key is used as "server key" (not visible to the users of your site but only used internally). If the API key is restricted to IPs and/or specific domains/url, it is unlikely to work.

  • @iionly hi i just tested vimeo and dailymotion with the same results it says it could not contact the site if i use the dailymotion short url format they have at dailymotion it says invalid url as far as youtube i do have the api setup and i have no restrictions set 

  • I should add that im using elgg 2.3.0 

  • i should also add that when i installed this plugin https://elgg.org/plugins/384562 it pulls youtube videos fine but it does not use an api so i guess hes doing things differently but it does not intergrate to hypewall etc as yours does 

  • I've just tested adding videos from all 3 sites on an Elgg 2.3 installation and it works. So, there shouldn't be an issue with iZAP Videos on Elgg 2.3.

    Have you added the video url with or without "http://" (or "https://")? I think it will fail without (and that might be a new item for my ToDo list). The Dailymotion short url will certainly not work (yet another item for my ToDo list). I always just copy+paster the url directly from the address bar of the browser. Right now I have no other idea why it doesn't work for you to add off-server videos apart from the url format. For Vimeo and Dailymotion there's surely nothing to set up. In case of Youtube the API key must be correctly set up. But if the other two sites also fail to work for you, it might not be an issue with the API key but maybe with the way you enter the video url. Or you might have tried it by coincidence with videos that are blocked by the uploader to be embedded on other sites. Though I guess it would fail with the Videos plugin then, too, for these videos (Videos plugin doesn't use the Youtube API and therefore needs no API key - but I can't fetch video title, description and tags then).

  • Well I monitored for a network connection while trying to retrieve a video I seen nothing no attempt to contact a remote server so I would think curl may be be failing though it does work with other scripts I also don't see anything in the PHP error logs also when checking in the API panel it shows no attempted contact with the API I have also disabled all firewalls etc to test it I'm running curl 7.49.1 should I try another version of curl perhaps

  • Have you checked the Server Analysis tab of the iZAP Videos settings page? Do you see any "Fails" there? Have you checked the disable_functions php config variable in php.ini? Maybe curl_exec() is not allowed. For on-server video support (in case you want that) you would also need to allow exec() to be used (i.e. not included in the list of functions in disable_functions).

  • I checked if any functions were disabled they are not I have errors on the ffmpeg lines and command interpreter line I assumed they were only important if I was going to be uploading videos so I did not bother with them

  • i have tried the following script and i get a 403 respons from the api i have tried the url in my browser and it works perfect any ideas maybe i setup the wrong type of key do i need browser key or server to server key


    Warning: file_get_contents(https://www.googleapis.com/youtube/v3/videos?part=snippet&id=): failed to open stream: HTTP request failed! HTTP/1.0 403 Forbidden in C:\Inetpub\vhosts\Nubbyswasteland.com\httpdocs\curl.php on line 7


    ini_set('display_errors', 1);

    $url = "https://www.googleapis.com/youtube/v3/videos?part=snippet&id=&quot;;

    echo file_get_contents($url);

  • Hi i fixed the issue i had to update my cacert.pem as curl works in ssl mode by default and my certificate was outdated so the connection was refused all works now vimeo youtube and dailymotion all i had to do was download a certificate from the curl website 

    thanks for you help and i love the plugin

  • any html5 player fallback for some mobile devices on this plugin or just flash player

  • Sorry. There's no html5 support yet. I have it on my ToDo list but so far had no time to work on it (and I have no idea at the moment when I will have some time to spare on it). I see the necessity for html5 support for sure. Possibly I switch from Flash to html5 completely (either with converting the existing on-server Flash videos to mp4 or at least setting mp4 for new videos the default format to convert into).

  • https://github.com/hypeJunction/elgg_file_viewer has a built-in video encoder and HTML5 player, in case you want to borrow some code.

  • @Ismayil Khayredinov Thanks. I'll take a look when I have time. But lack of time is my main problem.


  • Category: Media
  • License: GNU General Public License (GPL) version 2
  • Updated: 2020-9-1
  • Downloads: 9271
  • Recommendations: 19

Other Projects

View iionly's plugins