Compression with document handler

3 posts, 1 answers
  1. Lucania
    Lucania  avatar
    65 posts
    Member since:
    May 2011

    Posted 03 Apr 2012 Link to this post

    I have a handler that serves documents similar to this poster: http://www.telerik.com/community/forums/aspnet-ajax/compression/radcompression-ashx-content-length-header-flush.aspx 

    This stopped working when I enabled RadCompression, so I tried disabling it for the handler, but it still corrupts the reponse. I have verified that removing RadCompression completely fixes the problem, but I'd like to be able to use it for UI pages.

    Am I doing this right?

    Here's the relevant code from my web.config:
      <sectionGroup name="telerik.web.ui">
        <section name="radCompression" type="Telerik.Web.UI.RadCompressionConfigurationSection, Telerik.Web.UI, Version=2011.1.519.35, Culture=neutral, PublicKeyToken=121fae78165ba3d4" allowDefinition="MachineToApplication" requirePermission="false"/>
      </sectionGroup>
     
     
    <telerik.web.ui>
        <radCompression enablePostbackCompression="false">
            <excludeHandlers>
                <!--Exclude document handler -->
                <add handlerPath="*.wmdoc" matchExact="false"/>
            </excludeHandlers>
        </radCompression>
    </telerik.web.ui>
     
     
      <httpHandlers>
        <add type="MMS_Document" verb="*" path="*.wmdoc" validate="false"/>
      </httpHandlers>
  2. Answer
    Martin
    Admin
    Martin avatar
    811 posts

    Posted 04 Apr 2012 Link to this post

    Hello Ross,

    I am afraid that the handlerPath property does not support the wild card symbol '*'. Please try the following setting instead:

    <telerik.web.ui>
        <radCompression enablePostbackCompression="false">
            <excludeHandlers>
                <!--Exclude document handler -->
                <add handlerPath=".wmdoc" matchExact="false"/>
            </excludeHandlers>
        </radCompression>
    </telerik.web.ui>

    I hope this helps.

    Kind regards,
    Martin
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Lucania
    Lucania  avatar
    65 posts
    Member since:
    May 2011

    Posted 04 Apr 2012 Link to this post

    Thanks Martin that worked perfectly!
Back to Top