Welcome Guest Search | Active Topics | Sign In | Register

Double postback with Dialog and ContentUrl property Options
Yannick
Posted: Wednesday, November 28, 2007 8:10:50 AM
Rank: Member
Groups: Member

Joined: 10/25/2007
Posts: 16
Hello!

I'm using a Dialog to popup a page. I need to pass parameter to this page so i'm using setContentUrl property to pass parameter to the page.

here's the html code
Code: HTML/ASPX
<a href="javascript:eo_GetObject('DialogBuy').setContentUrl('BuyProduit.aspx?Produit=Prospecteur');eo_GetObject('DialogBuy').show(true);" class="LabelSold" id="lblProspecteur" runat="server">Requêtes restantes :</a>


Here's the Dialog
Code: HTML/ASPX
<eo:Dialog runat="server" id="DialogBuy" BorderStyle="Solid" ConfineElementID="divContainerMax" AnchorElementID="divPositionMouse" OffsetX="320" OffsetY="70"
	            AllowResize="False" ControlSkinID="None" Width="400px" BorderWidth="1px" Height="460px"
	            ShadowColor="LightGray" BorderColor="#335C88" ShadowDepth="3"
	            HeaderHtml="Dialog Header" ResizeImageUrl="00020014" BackShadeColor="Gray" ShowEffect-Duration="400" CloseEffect-Duration="300" ShowEffect-Type="Fade" CloseEffect-Type="Fade" 
	            ContentUrl="BuyProduit.aspx" >
	            <HeaderStyleActive></HeaderStyleActive>
	            <ContentStyleActive></ContentStyleActive>
	            <FooterTemplate>
		            <div>
			            <input type="button" id="btnDialogBuy_Cancel" value="Annuler" style="width:80px;margin-left:152px;margin-bottom:5px;" onclick="eo_GetObject('DialogBuy').close();" runat="server" />
			        </div>
	            </FooterTemplate>
            </eo:Dialog>


The problem is that the page is loaded twice.
Thank you!

eo_support
Posted: Wednesday, November 28, 2007 10:03:47 AM
Rank: Administration
Groups: Administration

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

That is normal. When the dialog is loaded the page will be loaded once without any argument and later loaded again with the correct argument. You should be able to easily change your server side code to ignore the request when there is no argument. Or change the initial contentUrl to a dummy empty page.

Thanks
Yannick
Posted: Wednesday, November 28, 2007 10:23:42 AM
Rank: Member
Groups: Member

Joined: 10/25/2007
Posts: 16
Hello!

I already tried to set the contentUrl to a dummy page with no success. The dummy page is not loaded and the other page is loaded twice.

And on each page load, arguments are there.

here's how I tested it...

Code: C#
sProduit = Request.QueryString["Produit"];


sProduit = Prospecteur on each page load.

Thanks
eo_support
Posted: Wednesday, November 28, 2007 12:10:48 PM
Rank: Administration
Groups: Administration

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

We have confirmed that this is a bug and have already fixed it internally. The fix will be in our next build.

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.