472,145 Members | 1,392 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,145 software developers and data experts.

ASP Session lost in IFRAME?

Hello,

I have a project in which I'm trying to embed one site, that uses
session stored variables, inside an IFRAME in another site (which for
that matter doesn't even use sessions).

Problem is, that it doesn't always save the session. When I try to
access it from some computers, I have no problem, the session variable
is stored and I can browse the site in the IFRAME and everything's ok,
but on other computers, the session variable value simply disappears.

To simulate the situation, assume that the two following html trees are
the site that goes into the IFRAME:

(called test.asp):

<html><head><title>test session</title></head>
<body>
<%
response.write "session var should be 123. var=" & session("var") &
"<br/>"
%>
<a href="test2.asp" >blah</a>
</body></html>

(called test2.asp):

<html><head><title>test session</title></head>
<body>
test2<br/>
<%
response.write "session var should be empty. var=" & session("var") &
"<br/>"
session("var")=123
response.write "session var should be 123. var=" & session("var") &
"<br/>"
%>
</body></html>

The following html tree simulates the other site with the first site
embedded in it (and they're not in the same domain...):

<html>
<head><body></body></head>
<body>
blah blah<br>
<iframe id="InnerIframe" src="test.asp" width=600 height=400></iframe>
<br>blah blah<br>
</body>
</html>

Again - this works when I work on one machine (WinXPSP2, IE6 or
FF1.5xx) but doesn't work on many other machines (one I tested it on -
Win2003 server, IE6).

Does anyone have any idea??

Thanks in advance,
R. Green

Jul 16 '06 #1
1 18749
zz****@gmail.com wrote:
I have a project in which I'm trying to embed one site, that uses
session stored variables, inside an IFRAME in another site (which for
that matter doesn't even use sessions).

Problem is, that it doesn't always save the session. When I try to
access it from some computers, I have no problem, the session variable
is stored and I can browse the site in the IFRAME and everything's ok,
but on other computers, the session variable value simply disappears.
http://aspfaq.com/show.asp?id=2157

--
Dave Anderson

Unsolicited commercial email will be read at a cost of $500 per message. Use
of this email address implies consent to these terms.
Jul 17 '06 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

reply views Thread by sean | last post: by
3 posts views Thread by karl | last post: by
2 posts views Thread by M | last post: by
reply views Thread by Van Steenbergen Jan | last post: by
3 posts views Thread by Mike | last post: by
3 posts views Thread by Timo | last post: by
1 post views Thread by Shahar Nechmad | last post: by
reply views Thread by tharika_c | last post: by
reply views Thread by Saiars | last post: by
reply views Thread by leo001 | last post: by

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.