?
avatar C-Lodder
C-Lodder
6 Aug 2017

Steps to reproduce the issue

If you have 2 instances of mod_wrapper on 1 page, then there will be 2 iframes with the same ID ('blockrandom').

  • Create 2 wrapper modules
  • Assign them both to the same page
  • Inspect the element and they will have the same ID

When a PR is submitted, they'll also have to update: https://github.com/joomla/joomla-cms/blob/staging/media/com_wrapper/js/iframe-height.js#L4

System information

  • Joomla staging
avatar C-Lodder C-Lodder - open - 6 Aug 2017
avatar joomla-cms-bot joomla-cms-bot - change - 6 Aug 2017
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - labeled - 6 Aug 2017
avatar franz-wohlkoenig franz-wohlkoenig - change - 6 Aug 2017
Title
2 instsnaces of mod_wrapper results in duplicate ID
2 instances of mod_wrapper results in duplicate ID
avatar joomla-cms-bot joomla-cms-bot - edited - 6 Aug 2017
avatar franz-wohlkoenig franz-wohlkoenig - change - 6 Aug 2017
Category com_modules
avatar franz-wohlkoenig
franz-wohlkoenig - comment - 9 Aug 2017

Issue confirmed.

avatar franz-wohlkoenig franz-wohlkoenig - change - 9 Aug 2017
Status New Confirmed
avatar DrDreave
DrDreave - comment - 31 Aug 2017

When examining the issue I noticed the media/com_wrapper/js/iframe-height.js isn't working properly in today's browsers. Enabling the auto height option in recent versions of Chrome and Firefox on MacOS has no effect.

e.g. Chrome throws:

Uncaught DOMException: Failed to read the 'contentDocument' property from 'HTMLIFrameElement': Blocked a frame with origin "http://joomla-git-sample.local" from accessing a cross-origin frame.
    at HTMLIFrameElement.contentDocumentDesc.get [as contentDocument] (<anonymous>:66:14)
    at iFrameHeight (http://joomla-git-sample.local/media/com_wrapper/js/iframe-height.min.js?84614c47e342ac58508eacfcd3d2d1ec:1:99)
    at HTMLIFrameElement.onload (http://joomla-git-sample.local/wrapper-module:162:19)

I think alternative approaches of setting the height should be discussed before reworking the id assignment to the wrappers.

avatar franz-wohlkoenig franz-wohlkoenig - change - 7 Nov 2017
Status Confirmed Discussion
avatar brianteeman
brianteeman - comment - 24 Dec 2017

Closed see #19136

avatar brianteeman brianteeman - change - 24 Dec 2017
Status Discussion Closed
Closed_Date 0000-00-00 00:00:00 2017-12-24 10:42:24
Closed_By brianteeman
avatar brianteeman brianteeman - close - 24 Dec 2017

Add a Comment

Login with GitHub to post a comment