hey again stackoverflowers
I'm migrating a website from old ASP (in VBScript) and there's certain stuuf I have to iFrame as to keep the old stuff working inside a new container.
on the aspx page I have an iFrame with the runat="server" attribute to make it available in the code behind file.
<iframe id="frmLoader" runat="server" scrolling="auto" width="100%" height="600px"></iframe>
now the issue, to get certain functionality I have to POST to a page (from the old site) to make it render differently and thus provide a response to the POST.
the following code resides in the Page_Load with of course parameters in the postData object
byte[] encData = new ASCIIEncoding().GetBytes(postData);
req.Method = "POST";
req.ContentType = "application/x-www-form-urlencoded";
req.ContentLength = encData.Length;
Stream dataStream = req.GetRequestStream();
dataStream.Write(encData, 0, encData.Length);
dataStream.Flush();
dataStream.Close();
WebResponse res = req.GetResponse();
StreamReader sr = new StreamReader(res.GetResponseStream());
string s = sr.ReadToEnd();
frmLoader.InnerHtml = s;
the pain here is that I can't seem to render the string into the iframe. with debugging I checked whether something should appear and it should, but it doesnt :p
anyone know how I get the string parsed into the iframe?
additionally, when triggering functionality in the iframe, the page should stay there, with the response to additional posts from the original site (old asp) I've been looking, but not finding answers.