[CLOSED] Resources from CDN and local red

  1. #1

    [CLOSED] Resources from CDN and local red

    I have a web application that runs on our local intranet and also used from outside , is possible configure to download resources from local server when accessing the local network and use CDN when accessed from outside
    Thank You
    Last edited by geoffrey.mcgill; Mar 19, 2015 at 2:07 AM. Reason: [CLOSED]
  2. #2
    Hello,

    If you can detect within the network or not, then you should be able to toggle setting the RenderScripts property to either ResourceLocationType.CDN or ResourceLocationType.Embedded.

    The RenderScripts property is also available as a Global setting which could be configured on the Session start, or during many other application instance events.

    Hope this helps.
    Geoffrey McGill
    Founder
  3. #3
    <script runat="server">
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!X.IsAjaxRequest && !RequestManager.IsMicrosoftAjaxRequest && HttpContext.Current != null && !HttpContext.Current.Request.IsLocal)
            {
                _rm.RenderScripts = ResourceLocationType.CDN;
                _rm.RenderStyles = ResourceLocationType.CDN;
            }
        }
    </script>
    <!DOCTYPE html>
    <html>
    <head runat="server">
    </head>
    <body>
        <ext:ResourceManager ID="_rm" runat="server" />
    </body>
    </html>
  4. #4
    thank you very much served me a lot of you are very kind

Similar Threads

  1. Replies: 3
    Last Post: Feb 06, 2013, 3:33 PM
  2. Replies: 8
    Last Post: Aug 04, 2010, 12:24 PM
  3. [CLOSED] The translation does not work using .net local file resources?
    By flormariafr in forum 1.x Legacy Premium Help
    Replies: 6
    Last Post: Feb 11, 2010, 2:45 PM
  4. [CLOSED] I got errors after generating Local resources files
    By flormariafr in forum 1.x Legacy Premium Help
    Replies: 2
    Last Post: Feb 11, 2010, 12:46 PM
  5. Replies: 1
    Last Post: Jul 29, 2009, 3:13 PM

Tags for this Thread

Posting Permissions