Welcome Guest Search | Active Topics | Sign In | Register

EO Dialog briefly shows previous ContentUrl Options
ibm5108735
Posted: Thursday, June 26, 2008 12:57:51 PM
Rank: Newbie
Groups: Member

Joined: 4/18/2008
Posts: 9
I have an issue where I have 1 EO Dialog control on a page, and several client-side links that cause it to display. Each client-side call to showModelPopup (see below) pass's a URL which is eventually set by setContentUrl() and a caption set by setCaption(). Each page that is displayed by the dialog has a Cancel button which will close the EO Popup.

The problem is that when the EO dialog appears any time after the initial call, the dialog box first shows the previous page set by setContentUrl() before quickly changing to the correct page.

Here is an example of how we reproduce it:
1) Clicking a link which we'll say display's "page1"
Example: <a href="javascript:showModelPopUp('page1.aspx','page1');">page1 link</a>

2) "page1" is displayed fine and has a cancel button which when clicked calls page.parent.closePopUp() (see closePopUp() below). We click the cancel button which closes the dialog. Everything is fine.

3) Then click a second link which we'll say display's "page2".
Example: <a href="javascript:showModelPopUp('page2.aspx','page2');">page2 link</a>

4) Observe that for a half second, the EO Dialog appears showing "page1.aspx" for before then rendering "page2.aspx".


So my question is how can we have a single EO dialog on a page that does not briefly display the previous content on subsequent calls to it? One solution we though of which we'd rather not do is to have one EO Dialog control in the ASPX for each client-side link that needs to display a dialog.

Please advise...




Below is some code samples take from our page:

Code: JavaScript
function showModelPopUp(url,title)
    {
        var dlg = eo_GetObject('Dialog1');
        dlg.setContentUrl(url);
        dlg.setCaption(title)
        dlg.show(true);
    }

    function closePopUp()
    {
        var dlg = eo_GetObject('Dialog1');
        dlg.close();
    }



Code: HTML/ASPX
<eo:Dialog runat="server" id="Dialog1" ContentUrl="~/blank.aspx" SkinID="eoPopWindow"  InitialState="Hidden" />

<a href="javascript:showModelPopUp('forgotpassword.aspx','Forgot Password ?');">Forgot My Password</a>

<a href="javascript:showModelPopUp(changepassword.aspx','Change Password ?');">Change Password</a>
eo_support
Posted: Thursday, June 26, 2008 1:21:55 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,194
Hi,

Yes. It does that. :) We actually switches the Url before it is displayed, but IE insists that there is no need to load the new page unless it is being displayed to the user. So as soon as the dialog is displayed, IE sees that it needs to display the new page and while it is loading the new page, you see the old page.

There is no easy workaround for this issue. One possible workaround is to always use a "landing page" in the dialog, then use that landing page to redirect to whatever other page you would like to load. That would involve a bit extra programming so you will want to judge whether it would be worth it.

Thanks


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.