0

OK, so my problem is I need to pass variables to an iFrame. I can do the following:

<iframe src="mypage.aspx?var=myvariable">

Which is fine, but ideally I'dlike to set up the request for the iFrame to have var stored in POST variable, as opposed to the GET. I'm pulling out what little hair I have left trying to solve this problem. Any gurus out there in SOLand got any ideas? TIA Peter

Bala R
  • 101,930
  • 22
  • 186
  • 204
sportsqs
  • 1
  • 1
  • 1

2 Answers2

1

As for posting to IFrame, check out this post. Perhaps, you could set a session variable in the parent page and retrieve it the page that's loaded by the IFrame.

Community
  • 1
  • 1
Bala R
  • 101,930
  • 22
  • 186
  • 204
0

You could also try and inherit both the parent page and the page contained in the iframe from a basepage. Putting in whatever variables you want and being able to call them at will. Something like.....

Create a seperate vb or c# whatever your flavor in your appcode folder. Call it BasePage

On your Iframe and Parent page put in your

Inherits BasePage Dim Public myvariable ....etc.

sleath
  • 843
  • 1
  • 12
  • 42