[WMTech] YouTube Load Enhancer [Deleted]

Do you think it works with 1.1.x?
I will upgrade to 1.3. in 2/3 months, but I have to install this addon now.

Yes it works even under 1.1, however only with small changes to the code. We do not release a version for 1.1, because we don"t like to make compromises. But if you like to sponsor the change, I'll be happy to adapt it for you. Please send me a PM if you like.

Is there a demo somewhere?

There is really nothing to see in a demo. All looks like before, just loaded locally and bypassing YouTube (until one decides to play the video of course). :-)
 
Yes it works even under 1.1, however only with small changes to the code. We do not release a version for 1.1, because we don"t like to make compromises. But if you like to sponsor the change, I'll be happy to adapt it for you. Please send me a PM if you like.



There is really nothing to see in a demo. All looks like before, just loaded locally and bypassing YouTube (until one decides to play the video of course). :)

When you first post a video, you see a crosshatched rectangle, not a thumbnail.
 
When you first post a video, you see a crosshatched rectangle, not a thumbnail.

This bug has been fixed with the most recent version (initial poster does not see the video picture immediately after posting). Please make sure that you've downloaded 1.0.2.

Crosshatched rectangles however usually are shown only after an error with YouTube. So this seems also like some special situation with that particular video.
 
I downloaded the latest, 1.0.2. Still happens.

We cannot reproduce this problem.

It may also be a special, rare situation with YouTube (such as requesting a HQ thumbnail which may not be available with that particular video, try to deactivate HQ thumbnails and see if that helps). All such errors will be corrected and handled automatically with this add-on, however the first guy who sees the video after he posted it (and only he and only one time) will get that YouTube error pic in such rare cases. Maybe we should intervene and change that to a generic "video will be loaded" pic with the next update?

If you want to send me the Youtube video id and your current settings, I could see if I can help.
 
@wmtech is it possibile to disable the cache generation (I'm using &controls=2 in the embed code) and still have Video Microdata?

p.s. to test &controls=2 without your addon I temporally uninstalled and the youtube bbcode configuration got deleted.!
 
Last edited:
Why not use something like this:

<iframe width="853" height="480" src="https://www.youtube.com/embed/{$id}?rel=0&autohide=1&controls=2&iv_load_policy=3" frameborder="0"></iframe>

controls=2 – Player controls display in the player. For IFrame embeds, the controls display and the Flash player loads after the user initiates the video playback.
https://developers.google.com/youtube/player_parameters#controls

I think you should post this into the XenForo suggestions forum. It would be perfect if XenForo changes its Youtube BB-Code to "controls=2". It doesn't harm and would make a speed improvement certainly!

However the purpose of this add-on is to NOT contact Youtube every time an embeded video is presented to every visitor and thus saving your visitor masses of Youtube cookies. Serving the content locally gives also even more speed improvement and not contacting YouTube gives a huge privacy improvement.

If you don't need this, this add-on is not for you. Simply changing the standard Youtube bb-code to include "controls=2" would be all you need. In fact this would be a change we can highly recommend each and every single XenForo owner.

@wmtech is it possibile to disable the cache generation (I'm using &controls=2 in the embed code) and still have Video Microdata?

p.s. to test &controls=2 without your addon I temporally uninstalled and the youtube bbcode configuration got deleted.!

Thank you for your suggestion. We'll consider this option in further development of this add-on.
 
Kintaro said:
@wmtech is it possibile to disable the cache generation (I'm using &controls=2 in the embed code) and still have Video Microdata?
We'll consider this option in further development of this add-on.
If this is done, i will instantly use this addon and buy rebranding removal :) I look further to an update with this or an ETA.
 
If this is done, i will instantly use this addon and buy rebranding removal :) I look further to an update with this or an ETA.

There will be an update soon which will remove the cache feature and just provides a speed improved BB code with this add-on.
 
How soon?

This won't happen as there are already some add-ons to just optimize the bb-media code.

Instead the next version of this add-on will go premium (no longer free) and get some additional professional features for larger, professional boards (to fit perfectly into our add-on portfolio).

Think about YouTube gallery with all clips posted anywhere at your site. Think also about member pages with all their posted youtube clips. etc, etc.
 
Think about YouTube gallery with all clips posted anywhere at your site.
You might want to consider what the Xenforo media gallery does with videos.
Sounds interesting, though.

All the same, it's specifically the loading of lots of YT videos on a page which is an issue for us.
 
You might want to consider what the Xenforo media gallery does with videos.
Sounds interesting, though.

This is different. Someone has to upload videos to XFMG to show it there. We all know, people do not like to upload pics and videos to a gallery and include it into their posts from there.

They just want to link YT clips and pics directly into their post.

All the same, it's specifically the loading of lots of YT videos on a page which is an issue for us.

This is exactly what this add-on is for. ;-)
It caches all YT video mockup locally to reduce the load at pages where many YT clips need to be loaded. The real YT clips loads only after someone wants to see it.

This drastically reduces the loading time with pages where a lot of YT videos are linked.
 
@wmtech

your addon works really well otherwise, but, within quotes, the embedded youtube player has a problem, it doesn't take up the whole space, instead becomes very small:

Screen Shot 2014-11-29 at 00.33.16.webp
 
@wmtech

your addon works really well otherwise, but, within quotes, the embedded youtube player has a problem, it doesn't take up the whole space, instead becomes very small:

View attachment 90566

Thanks for your notice. However, in the default style, it works as expected (responsive, expanding to the max possible space according to the browsers viewport and/or the settings you selected).

If you use a customized style you propably have to adapt the CSS too.
 
Thanks for your notice. However, in the default style, it works as expected (responsive, expanding to the max possible space according to the browsers viewport and/or the settings you selected).

If you use a customized style you propably have to adapt the CSS too.
Interesting... I tested with the default style, and still the same problem.

1.0.2 version of the addon and 1.4.3 XenForo.

Player Size: YouTube default for 16:9 ratio video (640x360 px), Align Center, Show No Links, everything else enabled except for Force Audio

Can anyone else reproduce the above problem of mine?
 
Thanks for your notice. However, in the default style, it works as expected (responsive, expanding to the max possible space according to the browsers viewport and/or the settings you selected).

If you use a customized style you propably have to adapt the CSS too.
I fixed it.

This CSS was the culprit:
Code:
.bbCodeQuote iframe, .bbCodeQuote object, .bbCodeQuote embed {
    max-height: 150px;
    max-width: 200px;
}

I put the following in EXTRA.css and now it works OK.
Code:
.bbCodeQuote iframe {
max-height: 100% !important;
max-width: 100% !important;
}
 
@wmtech

I have had to disable this add-on due to it hiding the whole post's content (and outputting a server error with each page load when viewing a thread page where there is a post with deleted youtube embed) when a video has been embedded in a post but when the video has been removed on YouTube later on.

Will this error happen with the new paid version if I buy it?

Posts that have valid (not deleted from YouTube) accessible youtube videos emdedded don't trigger this error message and everything works fine. Only posts which have youtube embed for a video that has since been deleted on YouTube will trigger this problem (the below error plus the post becoming completely empty when viewed, however when you edit the post, you can see the post's content, and when you remove the youtube media embed the post's content becomes fully visible again).

Server Error Log:

Error Info
Zend_Http_Client_Adapter_Exception: BB code to string error:Unable to Connect to tcp://i.ytimg.commqdefault.jpg:80. Error #0: php_network_getaddresses: getaddrinfo failed: Name or service not known - library/Zend/Http/Client/Adapter/Socket.php:235
Generated By: Unknown Account, 7 minutes ago

Stack Trace
#0 /home/xenforo/public_html/library/Zend/Http/Client.php(973): Zend_Http_Client_Adapter_Socket->connect('i.ytimg.commqde...', 80, false)
#1 /home/xenforo/public_html/library/WMTech/YTLoadEnhancer/Model/YtLoadEnhancer.php(111): Zend_Http_Client->request()
#2 /home/xenforo/public_html/library/WMTech/YTLoadEnhancer/YTLoadEnhancer.php(340): WMTech_YTLoadEnhancer_Model_YtLoadEnhancer->savePic('47WBh--ez_Q', 'http://i.ytimg....', 'maxresdefault.j...')
#3 [internal function]: WMTech_YTLoadEnhancer_YTLoadEnhancer::embedYT('47WBh--ez_Q', Array, 'youtube')
#4 /home/xenforo/public_html/library/XenForo/BbCode/Formatter/Base.php(1862): call_user_func_array(Array, Array)
#5 /home/xenforo/public_html/library/XenForo/BbCode/Formatter/Base.php(1742): XenForo_BbCode_Formatter_Base->_getMediaSiteHtmlFromCallback('47WBh--ez_Q', Array, 'youtube')
#6 /home/xenforo/public_html/library/XenForo/BbCode/Formatter/Base.php(652): XenForo_BbCode_Formatter_Base->renderValidTag(Array, Array, Array)
#7 /home/xenforo/public_html/library/XenForo/BbCode/Formatter/Base.php(565): XenForo_BbCode_Formatter_Base->renderTag(Array, Array, 0)
#8 /home/xenforo/public_html/library/XenForo/BbCode/Formatter/Base.php(546): XenForo_BbCode_Formatter_Base->renderTreeElement(Array, Array, 0)
#9 /home/xenforo/public_html/library/XenForo/BbCode/Formatter/Base.php(526): XenForo_BbCode_Formatter_Base->renderSubTree(Array, Array)
#10 /home/xenforo/public_html/library/XenForo/BbCode/Parser.php(505): XenForo_BbCode_Formatter_Base->renderTree(Array, Array)
#11 /home/xenforo/public_html/library/XenForo/BbCode/TextWrapper.php(119): XenForo_BbCode_Parser->render('Anybody know w...', Array)
#12 /home/xenforo/public_html/library/XenForo/Template/Abstract.php(265) : eval()'d code(2109): XenForo_BbCode_TextWrapper->__toString()
#13 /home/xenforo/public_html/library/XenForo/Template/Abstract.php(265): eval()
#14 /home/xenforo/public_html/library/XenForo/Template/Abstract.php(191): XenForo_Template_Abstract->_renderInternal('$__output = '';...', Array)
#15 /home/xenforo/public_html/library/XenForo/Template/Public.php(110): XenForo_Template_Abstract->render()
#16 /home/xenforo/public_html/library/XenForo/ViewRenderer/HtmlPublic.php(123): XenForo_Template_Public->render()
#17 /home/xenforo/public_html/library/XenForo/FrontController.php(618): XenForo_ViewRenderer_HtmlPublic->renderContainer(Object(XenForo_Template_Public), Array)
#18 /home/xenforo/public_html/library/XenForo/FrontController.php(158): XenForo_FrontController->renderView(Object(XenForo_ControllerResponse_View), Object(XenForo_ViewRenderer_HtmlPublic), Array)
#19 /home/xenforo/public_html/index.php(13): XenForo_FrontController->run()
#20 {main}

Request State
array(3) {
["url"] => string(62) "http://.../threads/living.2599/"
["_GET"] => array(1) {
["/threads/living_2599/"] => string(0) ""
}
["_POST"] => array(0) {
}
}
 
Top Bottom