Using a reverse proxy to enable all features of advanced iframe pro

In the quickstart guide you have found out which setup you have and which features are available for you. If you are on a different domain and you cannot add the line of Javascript than you normally cannot use features like auto height, css modifications or auto zoom.

The last option you might have is that you setup a so called reverse proxy (http://en.wikipedia.org/wiki/Reverse_proxy). If you run your own server or your hoster does allow that you use mod_proxy (http://httpd.apache.org/docs/current/mod/mod_proxy.html) AND you have access to the server config you can map the page you want in the iframe to a url of your site. Proxypass is not supported when you can only use a .htaccess file!

There are many tutorials about this topic. In my example below I use Five b from the following page: http://serverfault.com/questions/561892/how-to-handle-relative-urls-correctly-with-a-reverse-proxy.
A more detailed tutorial can be found here: http://www.apachetutor.org/admin/reverseproxies. Details about proxypass and proxypassreverse can be found here http://httpd.apache.org/docs/2.4/mod/mod_proxy.html#proxypass

So a reverse proxy setup can be quite simple but also not working at all depending on the page you want to include. And it does require a lot of time and is really an advanced topic.

As example I show you how I setup a reverse proxy on my localhost for the main page of www.tinywebgallery.com.

1. Enable mod_proxy and mod_substitute in conf/httpd.conf
2. Add

<IfModule proxy_module>
    ProxyPass /twg/ http://www.tinywebgallery.com/
    ProxyPassReverse /twg/ http://www.tinywebgallery.com/
    <Location /twg/>
      AddOutputFilterByType SUBSTITUTE text/html
      Substitute "s|www.tinywebgallery.com/|localhost/twg/|i" 
    </Location> 
</IfModule>

to the Apache config (conf/httpd.conf or e.g. extra/httpd-proxy.conf).

3. Restart the server

www.tinywebgallery.com is now available at http://localhost/twg/ ;).

And now you would be able to use all features of Advanced iFrame Pro!

Best, Michael

TWG 2.3 is available

TWG 2.3 has now also special settings for tablets. So you can now configure TWG for Desktop, tablet and smart phones!

Also some improvements for HTML5 videos and internal optimisations have been added.

This is the new stuff:

  • New: A couple new switches if a tablet is detected do exist now. See the internal_confif.php -> $twg_tablet_*
  • New: background images that a cached in the cache folder are removed once a day or if you delete the session cache because changing a back.png was really hard as you need to delete all cache images that belongs to the image.
  • New: Comments can only be entered when the page is inside an iframe. So direct entries through e.g. a bot doe not work anymore.
  • Fix: removed the “magic quotes GPC” check in the info as it is depricated and was removed in PHP 5.4
  • Fix: Pagination was reworked in 2.2 but failed for the default way. You should update to this version to get the correct pagination back!
  • Fix: Error “_folder_top.tmp.png’ could not loaded properly.” is now fixed. Was caused when image magic was used together with autocreation of folder.png files.
  • Fix: Undefined variable: twg_offset_
  • Fix: Undefined variable: my_offset_js
  • Fix: Removed folders caused an error messag in the log. This case is now detected.
  • Fix: html5 videos had some extra spaces which leads to a scrollbar on some systems.

So everyone should update to this version for best user experience on deskop and mobile devices.

You find the download and the patch on the normal download pages…

Have fun using TWG,

Michael

TWG 2.2 is available

TWG 2.2 is available

This are the important new features:

  • TWG has a new responsive mode for registered users.
  • Support for HTML5 videos! See the updated howto 34.
  • Many optimizations for mobile devices. Go the the ajax demo and go to the responsive folder.
  • Some hoster do report that a virus is in TWG. This is a false alarm but the part war rewritten to avoid this message.

This is the new stuff:

  • New: TWG goes responsive. Main, thumbnail and detail pages are responsive now. See the new howto 57 how to use this. This feature is available for registered users.
  • New: Support for HTML5 videos! See the updated howto 34.
  • New: Sorting mixed folders does now ignore v___. So sorting is not needed anymore only because of the video prefix.
  • New: New html mode selector images.
  • New: You can now set $use_manual_port if you are behind a proxy with a different port.
  • New: Additional media queries where added to improve support for mobile devices.
  • New: Optimization for ipad and iphone in horizontal mode.
  • New: Album and folder description use the dotdotdot jQuery plugin which cuts text with … if they cannot displayed anymore because of the screen size. See the first page of the ajax demo and reduce the browser size until you see the … ;).
  • New: Updated jQuery to 1.11.1
  • New: On smart phones the autodetect of thumbnails is disbled if the responsive mode is enabled on the thumb page because this can cause exteme big paginations.
  • New: On browser resize the new size is sent right away. So at the next request the size works fine right away.
  • New: TFU 3.2 included.
  • Fix: Swipe was not working on elements with links. This means on the detail page swiping was not working over an image.
  • Now a are excluded in the plugin and swiping should work now everywhere.
  • Fix: Some virus scanner where reporting a file of TWG which included some encoded code as virus. This is a false alarm but the code was changed to avoid that TWG is blocked by your hoster.
  • Fix: The pagination on the thumbnail page was wrong if you mix folders and thumbnails
  • Fix: Sorting for dates before 2000 (Length of the timestamp of 9)
  • Fix: Disabling the captions was disabling the edit of folder.txt and foldername.txt in the menu. Now this feature still works when captions are not shown.
  • Fix: iframe youtube and using a sorting prefix was not playing the first video.
  • Fix: Direct folder.png was not shown in php include mode.
  • Fix: Folder image was not shown when basedir was not default and SEO was enabled.

So everyone should update to this version for best user experience on deskop and mobile devices.

You find the download and the patch on the normal download pages…

Have fun using TWG,

Michael

JFUploader 3.2 and TFU 3.2 are available

Hi Everyone.

JFUploader 3.2 and TFU 3.2 are online now.
This is the new stuff:

  • New: Background of the flash can now be made transparent to integrate it better into your page. See c_bg_transpartent in the updated howto 9: http://www.tinywebgallery.com/en/tfu/tfu_faq_9.php
  • New: New plugin: watermark. You can now add a watermark directly after the upload. Thanks to Kulwinder Jootle to allow me to make this custom plugin public.
  • New: JFUploader 3.2 for Joomla 3.x does now support a new master mode: id_username
  • Fix: The Javascript callback previewSelect was called twice

Get the new versions here:
JFUploader: http://www.tinywebgallery.com/en/tfu/jfuploader-download.php
TFU: http://www.tinywebgallery.com/en/tfu/web_download.php

Have fun using JFUploader and TFU,
Michael

Advanced iframe pro 5.9 with lazy loading is available

Hi,

Advanced iframe pro version 5.9 is now on codecanyon
http://www.codecanyon.net/item/advanced-iframe-pro/5344999?ref=mdempfle

This is the new pro stuff:

  • New: Lazy load of iframes with treshold and fadein. Iframes can be loaded after the parent is done or the iframe is shown in the viewport! (Pro)
  • New: Better input validation. Avoids configuration errors.
  • New: WordPress 3.9.1 is supported
  • New: An alternative to the eval function is now used in Javascript to improve security and speed.
  • New: Browscap version 5029 lite 8th May 2014 is now included. (Pro)
  • Fix: Code improvements found with the plugin checker plugin
  • Fix: Hidden tabs was not working because of the responsive iframe feature. Now both do work independant again. (Pro)
  • Fix: Improved shortcode generator (Pro)
  • Fix: Width is now measured without the extra space (which was 0 by default anyway ;))
  • Fix: Whitelist for params was extended by :,? and &
  • Fix: Wrong default for Set Iframe height by ratio (iframe_height_ratio) was fixed (Pro)
  • Fix: loader icon and responsive iframe do now work together! (Pro)

Compare the free and the pro versions here:
http://www.tinywebgallery.com/blog/advanced-iframe/advanced-iframe-comparison-chart

Have fun using advanced iframe,
Best, Michael

TWG 2.1 is available

TWG 2.1 is available

Many small things where fixed to support IE 10 and 11 now even better.

This is the new stuff:

  • Fix: Important: Now Full IE11/IE10 support. The browser detection was not catching IE11/10 properly. Now IE11/10 are not running in compability mode anymore. You need php > 5.1.1 because the browser detection is used here.
  • Fix: Slideshow does now work with multiline captions
  • Fix: iframes of slideshow were increased slightliy to show the border on all browsers.
  • Fix: Button up is now centered always on the thumbnail page.
  • Fix: Iframe of slideshow is hidden until the iframe is loaded to avoid

So everyone should update to this version for best user experience on deskop and mobile devices.

You find the download and the patch on the normal download pages…

Have fun using TWG,

Michael

 

 

Advanced iframe pro 5.7 is available

Hi,

Advanced iframe pro version 5.7 is now on codecanyon
codecanyon.net/item/advanced-iframe-pro/5344999?ref=mdempfle

This is the new pro stuff:

  • New: html attribute allowfullscreen is now supported.
  • New: Zoom and auto height with the external workaround with several iframes on the same page is now supported.
  • Fix: Advanced iframe pro can now be used together with php-browser-detection. Before using both where leading to a function redeclaration.
  • Fix: Functions of the old and new workaround had the same name with different parameters. Now this functions have different names and also work properly with several iframes on the same page.

Compare the free and the pro versions here:
http://www.tinywebgallery.com/blog/advanced-iframe/advanced-iframe-comparison-chart

Have fun using advanced iframe,
Best, Michael

Responsive iframes with Advanced iFrame Pro

If you want to have a responsive iframe on your site the parent page AND the iframe page have to be responsive. If this is not the case you will not get the expected result.

If you google a little bit you find many solutions for responsive iframes.
Many of the solutions are only css based like

  • http://andmag.se/2011/11/responsive-embeds/
  • http://stackoverflow.com/questions/17838607/making-an-iframe-responsive

The big problem of this solutions is that they only work fine if the content is responsive AND you know the ratio of it. So it normally only works fine for videos and images. This scenarios are supported also: Responsive videos.

You also often find that you only need to set the style max-width:100% to the iframe.
But than you have an iframe with a responsive width but the problem with the correct height is still unsolved!

The solution is that the iframe needs to tell the parent its height after each resize.
This is easy if you are on the same domain but also possible if you are on different  domains. Due to the same-origin policy  an iframe at a different domain can’t use JavaScript to directly communicate with the parent page. Possible solutions are to use postMessage() or XSS communication using iframes.

-> To enable real responsive iframes you need to have access to the parent AND the iframe page.

Advanced iframe does already resize the iframe to its content height on the same domain and also on different domains using the XSS communication using iframes (I call it external workaround in the settings).

Advanced iframe pro version 5.6 does put all this together and does recalculate the height at each browser resize. The only thing you have to do is to enable responsive iframe and the auto height feature in the settings and use the external workaround if needed.

Summary:
– The parent and the page you want to include into the iframe need to be responsive!
– The iframe is on the same domain as the parent or you can modify the iframe page to use the external workaround.

See the working example in the pro demo: http://www.tinywebgallery.com/blog/advanced-iframe/advanced-iframe-pro-demo/responsive-iframes

If this does not apply for you the only other option which is maybe possible for you is to use auto zoom of the iframe. See
http://www.tinywebgallery.com/blog/advanced-iframe/advanced-iframe-pro-demo/auto-zoom-iframe-content

Get advanced iframe pro on codeyanyon: http://codecanyon.net/item/advanced-iframe-pro/5344999

Have fun using advanced iframe pro,
Michael

TWG 2.0.5 is available – Swipe support for all Tablets!

Hi everyone,

a new version for TWG is available.

Swipe support for all smart-phones AND tablets is available ;).

2.0.5
New: Swipe support is now available for all smart-phones AND tablets! A real mobile detection is now included and a jquery plugin for swipes is used!
Fix: Lighbox images where broken inside an iframe on some browsers. Now all tested browsers work fine.
Fix: Vertical images on top x are now centered.

2.0.4
New: Enable/disable the whole mobile detection: $enable_mobile_detection
Fix: Speedtest fixed. Was broken because of the 404 crawling “+ loc +” fix.

So please update to 2.0.5 to get the full support for mobile devices + no crawling error on google.

Have fun using TWG,
Michael