[Mono-bugs] [Bug 59794][Wis] New - problems with cookieless sessions and databinding
bugzilla-daemon@bugzilla.ximian.com
bugzilla-daemon@bugzilla.ximian.com
Tue, 8 Jun 2004 09:46:29 -0400 (EDT)
Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.
Changed by chris@turchin.net.
http://bugzilla.ximian.com/show_bug.cgi?id=59794
--- shadow/59794 2004-06-08 09:46:29.000000000 -0400
+++ shadow/59794.tmp.7974 2004-06-08 09:46:29.000000000 -0400
@@ -0,0 +1,95 @@
+Bug#: 59794
+Product: Mono: Class Libraries
+Version: unspecified
+OS: Mandrake 9.1
+OS Details:
+Status: NEW
+Resolution:
+Severity:
+Priority: Wishlist
+Component: Sys.Web
+AssignedTo: mono-bugs@ximian.com
+ReportedBy: chris@turchin.net
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL:
+Cc:
+Summary: problems with cookieless sessions and databinding
+
+I noticed that the coookieless sessions are still not working with
+gd-gallery using xsp/mod_mono from cvs. Maybe you could enable them in the
+test project i sent you (see attachment to bug:
+http://bugzilla.ximian.com/show_bug.cgi?id=58758) and see what i mean.
+perhaps it is a coding error on my part (do i have to do anything special
+for cookieless sessions?), but i don't think so...
+
+you will see what i mean if you try starting the app i sent you in the
+browser with cookieless sessions enabled, the images do not load because
+the uri's from the databinder are generated without a session key in the
+url. The code:
+
+<asp:DataList id="mediaList" runat="server" RepeatDirection="Horizontal"
+RepeatColumns="5" EnableViewState="false">
+ <ItemTemplate>
+ <asp:HyperLink id="galleryObjectLink"
+ NavigateUrl="<%# DataBinder.Eval(Container.DataItem,"Url") %>"
+ ImageUrl="<%# DataBinder.Eval(Container.DataItem,"Img") %>"
+ Runat="server">
+ </asp:HyperLink>
+ <asp:literal id="galleryObjectName">
+ <%# DataBinder.Eval(Container.DataItem,"Name") %>
+ </asp:literal>
+ </ItemTemplate>
+</asp:DataList>
+
+where:
+
+Url = "preview.aspx?img="+HttpUtility.UrlEncode(go.Path);
+
+in the data bound object yields this result:
+
+<td>
+<a id="mediaList__ctrl6a_galleryObjectLink"
+ href="/gd-gallery/preview.aspx?img=%2fdata%2fimages%2fimg_8967.jpg">
+<img
+src="/gd-gallery/thumbnail.ashx?fmt=Thumb&img=%2fdata%2fimages%2fimg_8967.jpg"
+border="0" />
+</img></a>
+
+and since the session key is not there, the link doesn't work. more
+precisely, the link is requested (the thumbnail.ashx from above for
+example) and then redirected to the thumbnail.ashx URL with a cookieless
+session key, but the parameters are lost in the process, so a link like:
+
+/gd-gallery/thumbnail.ashx?fmt=Thumb&img=%2fdata%2fimages%2fimg_8967.jpg
+
+when clicked becomes:
+
+/gd-gallery/(D341E3FBE1D999C9CF87DAA00C123B)/thumbnail.ashx
+
+which is also wrong (even if the parameters would have been maintained),
+since this is a new session and not the existing one.
+
+Actual Results:
+
+<img
+src="/gd-gallery/thumbnail.ashx?fmt=Thumb&img=%2fdata%2fimages%2fimg_8967.jpg"
+border="0" />
+
+Expected Results:
+
+<img
+src="/gd-gallery/(D341E3FBE1D999C9CF87DAA00C123B)/thumbnail.ashx?fmt=Thumb&img=%2fdata%2fimages%2fimg_8967.jpg"
+border="0" />
+
+where the session key is my current session key. the session key being
+assigned above when the page is redirected without parameters is a new key.
+
+How often does this happen?
+
+always, when cookieless sessions are activated.
+
+Additional Information:
+
+works fine when cookies are used. Test app attached to bug:
+http://bugzilla.ximian.com/show_bug.cgi?id=58758