Php photo gallery TWG | JFUploader | TWG Flash upload | WFU | Forum

Get help for TinyWebGallery, the best image gallery. The forum is also home for the Joomla JFUploader, TWG Flash Uploader and the Wordpress flash uploader.
It is currently 25. Nov 2024, 02:56

This forum is readonly now. Please use the new forum if you don't find the answer to your question here. The new forum is at https://www.tinywebgallery.com/blog/forum/


All times are UTC + 1 hour [ DST ]




Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: Hide elements in iframe
PostPosted: 7. Apr 2020, 03:36 
Offline

Joined: 7. Apr 2020, 03:28
Posts: 1
Hi there,

I'm trying to hide the menu from this page: https://www.tridentresults.com on here: https://onetime.sport/events/

I'm using this short code but can't get it to work:

[advanced_iframe src="https://www.tridentresults.com" width="100%" height="1400" hide_elements=".header navbar yamm navbar-default navbar-static-top fixedheader,.fixedheader-spacer"]

I managed to hide the menu using google console with this code:

var all = document.getElementsByClassName('navbar yamm navbar-default navbar-static-top fixedheader');
for (var i = 0; i < all.length; i++) {
all[i].style.display = 'none';
}
var all = document.getElementsByClassName('fixedheader-spacer');
for (var i = 0; i < all.length; i++) {
all[i].style.display = 'none';
}

Please help! :)

If you could provide the code to hide the footer as well that would be great.

Thanks
Connar


Top
 Profile  
 
PostPosted: 7. Apr 2020, 20:24 
Offline
Site Admin
User avatar

Joined: 1. Aug 2005, 12:53
Posts: 11232
Hi

https://www.tridentresults.com and
https://onetime.sport/events/

are different domains! so you don't have direct access.
You need to use the external workaround to hide elements in the iframe.

Please see here:
http://www.tinywebgallery.com/blog/advanced-iframe/advanced-iframe-pro-demo/external-workaround-with-post-message
for a working example.

If you don't have access then putting a kind of viewport over the iframe is the other option:
http://www.tinywebgallery.com/blog/advanced-iframe/advanced-iframe-pro-demo/show-only-a-part-of-the-iframe
http://www.tinywebgallery.com/blog/advanced-iframe/advanced-iframe-pro-demo/hide-a-part-of-the-iframe

Best, Michael


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC + 1 hour [ DST ]


Who is online

Users browsing this forum: No registered users and 14 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
powered by phpbb | Datenschutz/ Privacy policy