Losing session after file uploading

Thread is closed for posting
5 posts, 1 answers
  1. Bram
    Bram  avatar
    4 posts
    Member since:
    Nov 2007

    Posted 23 Aug 2008 Link to this post

    Hello,

    We are using DNN 4.8.2 Portal with some subportals. Some of our modules are using Telerik controls to upload files. On the main portal all works fine, but on the subportals we have a problem
    with Telerik RadProgressManager / RadProgressArea controls.
    So you can browse and select a file, view progress bar, but once the upload has completed, session will be lost immediately.  It appears because of some cookies are removed: .DOTNETNUKE, portalaliasid, portalroles. As I mentioned before these cookies will be lost on sub portals only – on the main portal they will still present after upload is finished.  If progress bar is not used everything will works fine.

    We are using 2008.1.619.35 version (RadControls_for_ASP.NET_AJAX_2008_1_619_dev.exe).

    DNN configuration:

    Web.config
    <configuration>

    <location path="Telerik.RadUploadProgressHandler.ashx">
                <system.web>
                            <authorization>
                                       <allow users="*" />
                            </authorization>
                </system.web>
    </location>

    <httpModules>
                …
                <add name="RadUploadModule" type="Telerik.Web.UI.RadUploadHttpModule, Telerik.Web.UI" />
    </httpModules>

    <httpHandlers>

        <add verb="*" path="Telerik.RadUploadProgressHandler.ashx" type="Telerik.Web.UI.RadUploadProgressHandler, Telerik.Web.UI" /></httpHandlers>

    </configuration>

    SiteUrls.config are:

    <?xml version="1.0" encoding="utf-8" ?>
    <RewriterConfig>
                <Rules>
                            <RewriterRule>                                       
                                       <LookFor>.*Telerik.RadUploadProgressHandler.ashx(.*)</LookFor>
       
                                    <SendTo>~/Telerik.RadUploadProgressHandler.ashx$1</SendTo>
                            </RewriterRule>
                            <RewriterRule>
    ...
    </RewriterConfig>


    What can cause such behavior? Is it connected to issue http://www.telerik.com/community/forums/thread/b311D-dtgtt.aspx? How it can be fixed?

    Regards,

    Jochem

  2. Erjan Gavalji
    Admin
    Erjan Gavalji avatar
    1455 posts

    Posted 25 Aug 2008 Link to this post

    Hi Jochem Nuij,

    Did you modify DNN's URL Rewriter rules?

    This should be done by opening the SiteUrls.config file from the DotNetNuke\Website folder in a text editor and add the following before the other <RewriterRule> tags:

    <RewriterRule>
    <LookFor>.*Telerik.RadUploadProgressHandler.ashx</LookFor>
    <SendTo>~/Telerik.RadUploadProgressHandler.ashx</SendTo>
    </RewriterRule>

    This will allow RadUpload's URLs to be handled properly by DNN's URL Rewriter. Please note, that RadUpload's RewriterRule should be the first one in the list.

    Kind regards,
    Erjan Gavalji
    the Telerik team

    Check out Telerik Trainer, the state of the art learning tool for Telerik products.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Bram
    Bram  avatar
    4 posts
    Member since:
    Nov 2007

    Posted 26 Aug 2008 Link to this post

    Yes, but unfortunately it didn’t help.

    Our SiteUrls.config look like:
    <?xml version="1.0" encoding="utf-8" ?>
    <RewriterConfig>
                <Rules>
                            <RewriterRule>
                                      <LookFor>.*Telerik.RadUploadProgressHandler.ashx</LookFor>
                                      <SendTo>~/Telerik.RadUploadProgressHandler.ashx</SendTo>
                            </RewriterRule>
                            <RewriterRule>
                                       <LookFor>.*DesktopDefault.aspx(.*)</LookFor>
                                       <SendTo>~/Default.aspx$1</SendTo>
                            </RewriterRule>
                            <RewriterRule>
                                       <LookFor>.*EditModule.aspx(.*)</LookFor>
                                       <SendTo>~/Default.aspx$1</SendTo>
                            </RewriterRule>
                            <RewriterRule>
                                       <LookFor>.*/TabId/(\d+)(.*)/Logoff.aspx</LookFor>
                                       <SendTo>~/Admin/Security/Logoff.aspx?tabid=$1</SendTo>
                            </RewriterRule>
                            <RewriterRule>
                                       <LookFor>.*/TabId/(\d+)(.*)/rss.aspx</LookFor>
                                       <SendTo>~/rss.aspx?TabId=$1</SendTo>
                            </RewriterRule>
                            <RewriterRule>
                                       <LookFor>[^?]*/TabId/(\d+)(.*)</LookFor>
                                       <SendTo>~/Default.aspx?TabId=$1</SendTo>
                            </RewriterRule>
                </Rules>
    </RewriterConfig>

    I tried to place SiteUrls.config file to DotNetNuke\Website (subportal) folder. But on subportal cookies are still lost.

    Regards,

    Jochem
  5. Answer
    Blaize
    Blaize avatar
    88 posts
    Member since:
    Oct 2006

    Posted 26 Aug 2008 Link to this post

    Hi Jochem,

    Not sure if that will help, but you might try the following:

    <RewriterRule>
        <LookFor>
    [^?]*/TabId/(\d+)(.*)Telerik.RadUploadProgressHandler.ashx</LookFor>
        <SendTo>~/Telerik.RadUploadProgressHandler.ashx
    ?TabId=$1</SendTo>
    </RewriterRule>


    Cheers,
    Blaize
  6. Jesse
    Jesse avatar
    5 posts
    Member since:
    Feb 2009

    Posted 07 May 2009 Link to this post

    This is more or less the same thing, but if you'd rather handle it in code, this is what worked for us:

    Radprogressmanager1.AjaxUrl = Page.ResolveUrl("~/Telerik.RadUploadProgressHandler.ashx") & "?TabId=" & TabId
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017