Click here to Skip to main content
16,020,840 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hey,

I am just trying to get the following scenraio to run:
- My vb.net page is getting via querystring a web page.
- the sent webpage should get loaded
- during the loading process a div for example should get displayed
- when the request page is loaded, the div should get hidden and the requested page should get displayed

Do you have any suggestions how to do that?

Thanks in advcance,
Arthur
Posted
Comments
Sergey Alexandrovich Kryukov 10-Jul-13 11:04am    
Do you want to show div when it is not yet loaded? :-)
—SA

Please see this CodeProject solution: Loading Message when Page Loads[^].

(I did not try it though.)

—SA
 
Share this answer
 
One option for you is to send a response with (only) the div you want to show.
PLUS a background JS that will request the page content and make the switch after it loads.

Good luck,
Edo
 
Share this answer
 
Hey,

thanks for your post.
Unfortunately I forgot to mention that the requested page has to get displayed in the same page because the requested page does have a lot of meta tags I need for my google ad words. And Google Ad words is just tracking the first page which is requesting the second page :)

Thanks
 
Share this answer
 
Does anybody of you know how solve that problem?
Thanks
 
Share this answer
 
hey!

Finally, I was able to find out a work around by myselef:
First I added the following code:

html,body,iframe { height:100%; width:100%; overflow:hidden; margin:0; padding:0;}


$(document).ready(function () {

$('body').append($('<iframe id="myIframe" width="100%" border="0" style="overflow:scroll"></iframe>'));
$('#myIframe').attr('src', 'www.linktothesite.com');

$.lightbox('something.aspx', {
iframe: true,
width: 800,
height: 500
});
return false;
})







In the codebehind I am doing this:
Dim webrequest As WebRequest = webrequest.Create("www.linktothesite.com")

Dim WebResponse As WebResponse = webrequest.GetResponse()

Dim webreader As StreamReader = New StreamReader(WebResponse.GetResponseStream(), Encoding.ASCII)
Dim webcontent As String = webreader.ReadToEnd
noFramesContent.InnerHtml = HttpUtility.UrlDecode(webcontent)

I dont know yet if this solution is working for ggogle as well :)

cheers
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900