Changing page objects at run time

This section is for posting questions which are not directly related to WYSIWYG Web Builder.
Examples of off topics: web server configuration, hosting, programming related questions, third party scripts.

Note that these questions will generally not be answered by the administrators of this forum.
Post Reply
User avatar
alex4orly
 
 
Posts: 744
Joined: Mon Jan 20, 2014 8:17 am
Location: Australia
Contact:

Changing page objects at run time

Post by alex4orly » Wed May 15, 2019 7:35 am

Please have a look at this link:
https://communitylifestyleaccommodation ... ources.php
At the bottom of the page there is a Text line - Text5

On clicking the link - I trigger two evants :
1st- Hide the text object Text5
2nd - Call Javascript : window:reload(true);

I now want to stretch vertically the iFrame to fill up the extra space cleared at the bottom of the page

Any idea on how to do that?

Thanks

User avatar
[RZ]
 
 
Posts: 2092
Joined: Tue Nov 04, 2008 12:08 pm

Re: Changing page objects at run time

Post by [RZ] » Wed May 15, 2019 7:41 am

what the browser does from the server is correct
the page is loaded and the initial visibility of the object is visible by default
if you want to reload the page and remain the object hidden you must use cookies

User avatar
alex4orly
 
 
Posts: 744
Joined: Mon Jan 20, 2014 8:17 am
Location: Australia
Contact:

Re: Changing page objects at run time

Post by alex4orly » Wed May 15, 2019 8:28 am

Hello RZ,

Sorry, maybe I didn't explain myself.
The einitial page load, shows a html page inside an iFram
The iFrame is shorter in height to allow space for the text item at the bottom

Once this text item is gone, I want the new page to load into a higher iFrame
Therefore, I want to stretch the iFrame Vertically

Any idea how?
Thanks

User avatar
[RZ]
 
 
Posts: 2092
Joined: Tue Nov 04, 2008 12:08 pm

Re: Changing page objects at run time

Post by [RZ] » Wed May 15, 2019 9:12 am

yes
it requires:
1) advanced programming knowledge
2) same domain for both pages

User avatar
alex4orly
 
 
Posts: 744
Joined: Mon Jan 20, 2014 8:17 am
Location: Australia
Contact:

Re: Changing page objects at run time

Post by alex4orly » Wed May 15, 2019 10:42 pm

I created a test page here : https://communitylifestyleaccommodation ... retch.html
I created a simple Javascript function in the Header section with this code:

<script type="text/javascript">
function stretchiFrame()
{
getElementById('InlineFrame1').height = "200";
}
</script>

In the events for the link
1) I hide the Text5 element
2) I call the function above
3) I call the Javascript : window(reload(true);

But, it doesn't chenage the iFrame height

Any suggestions?

Thanks

User avatar
Pablo
 
Posts: 16888
Joined: Tue Mar 28, 2006 12:00 pm
Location: Europe
Contact:

Re: Changing page objects at run time

Post by Pablo » Thu May 16, 2019 6:08 am


User avatar
alex4orly
 
 
Posts: 744
Joined: Mon Jan 20, 2014 8:17 am
Location: Australia
Contact:

Re: Changing page objects at run time

Post by alex4orly » Thu May 16, 2019 6:22 am

Thanks Pablo,

Too complex for what I want, I can simply create another page with the new iFrame and swicth between
My case does NOT depand on content, it is a one size change only

Cheers

Post Reply