473,770 Members | 2,171 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Tricky IFrame Problem (yes it's about the dynamic height, again)

Hey Guys,
I've done my research for a script that dynamically adjusts the height
of the Iframe, but none of the scripts have the features, which I all
need. Maybe one of you can help me:

1. The site contained in the Iframe is no on the same Domain nor Server
as the main page

2. I can't put any code in the Iframe (YES, I do have permission to
include the Iframe ;-)

3. The height needs to adjust not just the first time the mainpage
loads, but also everytime somebody opens a new site in the Iframe. The
height needs to be readjusted in that case, too.

If the script works for IE only, it'll be better than nothing (as long
as it works for other browsers with scrollbars) and if it works for IE
and Mozilla only I'm good.

Alright.. I hope somebody can help me. I'd be veeeeery grateful.
Thanks.
Flo from Berlin.

Oct 7 '06
11 6012
Here's what I've found:

iFrames can contain pages from other domains, but server security
settings will not allow scripting cross domain. In other words - you
will not be able to use a script to determine the size of the pages
you're loading into your iFrame.

Source:http://support.microsoft.com/kb/q278469/

There is a possible solution, but requires php implementation:

Source: http://www.daniweb.com/techtalkforum...199610-12.html

"I wrote a PHP proxy script that has some applications relevant to this
thread, so thought I'd update the thread with this....

If your webserver supports PHP, I have a script that is a solution to
the cross-domain security issues when doing things such as AJAX
requests, etc. Instead of directly requesting the content, request my
proxy.php passing in the real URL that you want. The proxy.php script
will go fetch the content for you and forward back that response to
your client script. It echoes back the full headers and response body.

proxy.php
http://www.troywolf.com/articles/php...ttp/proxy.phps

One problem people run into when using a proxy to get content is that
relevant URLs in links break. You can solve this by parsing the body
text, look for links, and if the link does not start with 'http://',
insert the original site url. It's not exactly a simple thing to do,
but a solution I've built in the past."

I'm going to try and implement this as soon as I have the time. I hope
it helps.

Francois.

Oct 11 '06 #11
TC

fran.carst...@g mail.com wrote:
iFrames can contain pages from other domains, but server security
settings will not allow scripting cross domain.
It's nothing to do with the server. It's implemented by the browser.
There's nothing to stop a browser allowing cross-frame scripting,
should it wish to do so. Indeed, IE has a setting for this - not that
you'd want to actually -use- that setting.

HTH,
TC (MVP MSAccess)
http://tc2.atspace.com

Oct 11 '06 #12

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
7620
by: Thomas | last post by:
Hi there, I have an iframe which is editable (designMode = "on") and want to resize it dynamically as the content grows (e.g. more lines of text is in there) and there the struggle starts. I fill the iframe with content (<body> tag and so on and also insert a <div> tag, inbetween is the content that should be modified). Now if the event "overflow" or "underflow" is triggered the iframe
2
47344
by: Templar | last post by:
Hi i'm bothering with such problem... I must dynamic create an Iframe, and then put som raw HTML into it. But I can't. When I create iframe, I can't access its properties. Here's the coe snipplet: //************************************* //*************************************
6
4961
by: SF RVN | last post by:
I have searched NUMEROUS sources in an effort to find the magic (script, styles, syntax, etc.) that will allow me to create a web page with the following format: |----------------------------------------------------------------| | Discrete table used as 'banner' | | DONE! | |----------------------------Table 1-----------------------------| ...
1
2691
by: Robert de Ridder | last post by:
I use an asp page to display pages, where the dynamic content is in an iframe. To calculate the height of the iframe I use the calcheight function. However when trying to do this with external pages, I get an access denied error, and the iframe won't display correctly. Is there a way to solve this or another way to calculate the height for the iframe. The relevant code displayed below. Thanks in advance for any help,
0
5893
by: dimepiece18 | last post by:
On our Intranet homepage, I have a layer with an iframe contained in it. The iframe is linked to an html document that is stored in our Content Library system. You have to be authorized to view the documents in Content Library. The problem I'm having is that when you launch the Intranet site, the SSO login screen appears, but it looks like the iframe is trying to launch the html file before the homepage loads. So after you log in, the iframe...
8
5373
by: hyejin | last post by:
I have a problem with dynamic iframe and document.close() on Firefox. Below two files create a dynamic iframe by JavaScript. These two samples do not have any problems on IE. But, on Firefox, the icon on the top corner keeps running with "loading" message on the bottom status bar even though the browser completed everything in the iFrame. The line that causes the problem is "document.close()" in the included JS file. If this line is...
3
5400
polymorphic
by: polymorphic | last post by:
I have succeeded in embedding PDF files in a dynamic iframe. The problem is that I need the PDF to cache. If the PDF remains the same from page load to page load then the pdf is somehow cached with the html page. But if I try to navigate to another pdf in the IFRAME then no caching occurs. Is the problem in the IFRAME reloading instead of just refreshing the pdf? <SCRIPT type="text/javascript"> var pageNo; var nav; var iframe; var...
0
9619
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10260
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10102
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9910
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8933
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7460
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5482
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
2
3609
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2850
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.