Custom CDN Provider

5 posts, 0 answers
  1. Tarek
    Tarek avatar
    23 posts
    Member since:
    Mar 2013

    Posted 22 Dec 2013 Link to this post

    How these operations are translated in web.config file :

    Set HTTP headers

    • Cache-Control: public, max-age=31536000

    • Expires - 1 year from the date of the request, if set dynamically. Far-future date (10 years) if set statically.

    • For all files in the Scripts/ajaxz folder: Content-Encoding: gzip

    • For .css files in the Skins/ajaxz folder: Content-Encoding: gzip

  2. Peter Filipov
    Admin
    Peter Filipov avatar
    1028 posts

    Posted 25 Dec 2013 Link to this post

    Hi Tarek,

    Here you could find more information about the caching. Regarding to the compression my advice is it to enable it on the application level.

    Regards,
    Peter Filipov
    Telerik
    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 the blog feed now.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Eirik H
    Eirik H avatar
    36 posts
    Member since:
    Mar 2010

    Posted 08 Apr 2014 in reply to Tarek Link to this post

    Hi! What is you recommendation to do this in IIS:

    For .css files in the Skins/ajaxz folder: Content-Encoding: gzip
  5. Peter Filipov
    Admin
    Peter Filipov avatar
    1028 posts

    Posted 09 Apr 2014 Link to this post

    Hello Erik,

    You could use RadCompression or the dynamic compression described in the provided help article.

    Regards,
    Peter Filipov
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  6. Eirik H
    Eirik H avatar
    36 posts
    Member since:
    Mar 2010

    Posted 09 Apr 2014 in reply to Peter Filipov Link to this post

    I'm not sure how that would apply as the files are already compressed, but anyway, we ended up with the following web.config in the ajaxz folder:
    <?xml version="1.0" encoding="UTF-8"?>
    <configuration>
        <system.webServer>
            <staticContent>
                <clientCache cacheControlMode="UseMaxAge" cacheControlMaxAge="365.00:00:00" />
            </staticContent>
            <rewrite>
                <outboundRules>
                    <rule name="Set custom HTTP response header">
                        <match serverVariable="RESPONSE_Content_Encoding" pattern=".*" />
                        <conditions>
                            <add input="{REQUEST_URI}" pattern="\.css$|\.js$" />
                        </conditions>
                        <action type="Rewrite" value="gzip"/>
                    </rule>
                </outboundRules>
            </rewrite>
        </system.webServer>
    </configuration>

Back to Top
UI for ASP.NET Ajax is Ready for VS 2017