Crossdomain Wrapper Autoheight: Difference between revisions

From Joomdle
Jump to navigationJump to search
Created page with "Joomdle can integrate with 3rd party library iframe-resizer (https://github.com/davidjbradshaw/iframe-resizer) to allow for auto-height on multiple domain setup scenarios. To..."
 
No edit summary
 
(3 intermediate revisions by the same user not shown)
Line 4: Line 4:


'''Joomla:'''
'''Joomla:'''
* Enable option " Cross-domain auto-height" in Joomdle configuration in Joomla, in "Links behaviour" section.
* Enable option " Cross-domain auto-height" in Joomdle configuration in Joomla, "Links behaviour" section.


'''Moodle:'''
'''Moodle:'''
Line 11: Line 11:
* Copy file moodle/auth/joomdle/js/iframeResizer.contentWindow.min.js to moodle/theme/YOUR_THEME/javascript
* Copy file moodle/auth/joomdle/js/iframeResizer.contentWindow.min.js to moodle/theme/YOUR_THEME/javascript
* Finally, add the new javascript file to your theme, by opening moodle/theme/YOUR_THEME/config.php and adding at the end:
* Finally, add the new javascript file to your theme, by opening moodle/theme/YOUR_THEME/config.php and adding at the end:
** $THEME->javascripts = array ( 'iframeResizer.contentWindow.min' );
* or, if $THEME->javascripts is already defined in file:
** $THEME->javascripts[] = 'iframeResizer.contentWindow.min';


$THEME->javascripts = array ( 'iframeResizer.contentWindow.min' );


After these steps, you should be able to have resizing iframe over different domains


After these steps, you should be able to have resizing iframe over different domains
 
'''NOTE:''' This is a new feature that has only been tested in a few sites, so please report any issues you may have with it.

Latest revision as of 17:34, 11 December 2017

Joomdle can integrate with 3rd party library iframe-resizer (https://github.com/davidjbradshaw/iframe-resizer) to allow for auto-height on multiple domain setup scenarios.

To use this, however, you will need to do additional configuration in Joomla and Moodle:

Joomla:

  • Enable option " Cross-domain auto-height" in Joomdle configuration in Joomla, "Links behaviour" section.

Moodle:

  • In the file system, locate the folder of the theme you are using in Moodle.
  • Create, if it does not exists, moodle/theme/YOUR_THEME/javascript
  • Copy file moodle/auth/joomdle/js/iframeResizer.contentWindow.min.js to moodle/theme/YOUR_THEME/javascript
  • Finally, add the new javascript file to your theme, by opening moodle/theme/YOUR_THEME/config.php and adding at the end:
    • $THEME->javascripts = array ( 'iframeResizer.contentWindow.min' );
  • or, if $THEME->javascripts is already defined in file:
    • $THEME->javascripts[] = 'iframeResizer.contentWindow.min';


After these steps, you should be able to have resizing iframe over different domains


NOTE: This is a new feature that has only been tested in a few sites, so please report any issues you may have with it.