Rank: Newbie Groups: Member
Joined: 11/24/2008 Posts: 5
|
Hello, I am using eo:dialog to display a "Waiting ..." message when a user press a button in a page. This works fine in IE but in FireFox the ContentUrl is not displayed! Here is the relative code:
===========================================================
<eo:Dialog runat="server" id="Dialog1" BorderStyle="Solid" CloseButtonUrl="00070101" MinimizeButtonUrl="00070102" AllowResize="True" ControlSkinID="None" Width="300px" BorderWidth="1px" Height="200px" ShadowColor="gray" BorderColor="#335C88" RestoreButtonUrl="00070103" ShadowDepth="30" HeaderHtml="Infomrational Message" ResizeImageUrl="00020014" BackShadeColor="#000000" ContentUrl="/han/online/process_dialog.html"> <HeaderStyleActive CssText="padding-right: 4px; padding-left: 4px; font-size: 11px; background-image: url(/han/media/pages/white_spacer.gif); padding-bottom: 3px; padding-top: 3px; font-family: tahoma"></HeaderStyleActive> <ContentStyleActive CssText="border-top: #335c88 1px solid; background-color: #e5f1fd"></ContentStyleActive> </eo:Dialog>
==================================================
The dialog is displayed with this javascript function, which then calls the start.aspx page:
function start12(){ eo_GetObject('Dialog1').show(true); document.body.style.cursor = "wait"; document.location = "/han/online/start.aspx?page=12"; }
Also if i delete the line
document.location = "/han/online/start.aspx?page=12";
then the dialog is displayed correctly, but this is not the point as I want my page to redirect and this works fine in IE.
Any assistance is kindly appreciated.
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,194
|
Hi,
That will not work. The dialog is a part of the containing page and if you switch the containing page, the page will be unloaded. When the page is being unloaded, the dialog will started to be destroyed. The reason that it appears to be working for you on IE is because IE gets the new page from the server first, then unload the old page; Where as FireFox unload the old page first, then starts to get the new page. There is no clear rule on this so different browsers are free to implement it whatever way they see fit. As a result, you can not code based on that.
The only reliable way to display a "wait" message is to use AJAX. In that case you never switch the containing page, but only switching/updating a portion of the page.
Thanks!
|