[CLOSED] Caching common part of UI

  1. #1

    [CLOSED] Caching common part of UI

    Greetings,

    I have a requirement of caching/storing common part of UI on client browser so that the navigation wont look like a full postback or refresh.
    I am relatively new to ext.net so am not much aware of the features of it.

    Can you please provide me some solution to the requirement or suggest any path through which I can achieve that using ext.net.
    Last edited by Daniil; Mar 26, 2013 at 4:18 AM. Reason: [CLOSED]
  2. #2
    Hi @vijay.sahu,

    Well, you could cache something in cookies. But it would be rather some data, not UI.

    Please provide more details. What exactly do you need to "cache"?

    so that the navigation wont look like a full postback or refresh
    I guess it is rather a problem of the application's design. If you don't need to refresh some part of the page, you should not reload it.

    For example, please open some examples here (clicking the tree's nodes).
    http://examples.ext.net

    As you can see it doesn't refresh the whole page, but just loads and renders the requested things.
  3. #3
    Hi Daniil,

    We are trying to achive RIA look for our applications.

    Please refer image for more clarification. We would like to refresh only the central panel (bordered panel) without using iframe and load different content on clicking the different links of the tree rather than refreshing the whole page and expanding the tree.

    In the http://examples.ext.net url, the contents are loaded in different tabs on clicking the tree nodes which is not what we are actually looking for.

    It would be great if you would be able to provide any solution available for such a scenario.




    Quote Originally Posted by Daniil View Post
    Hi @vijay.sahu,

    Well, you could cache something in cookies. But it would be rather some data, not UI.

    Please provide more details. What exactly do you need to "cache"?



    I guess it is rather a problem of the application's design. If you don't need to refresh some part of the page, you should not reload it.

    For example, please open some examples here (clicking the tree's nodes).
    http://examples.ext.net

    As you can see it doesn't refresh the whole page, but just loads and renders the requested things.
    Attached Thumbnails PanelReload.jpg  
    Last edited by vijay.sahu; Mar 20, 2013 at 12:25 PM.
  4. #4
    You can achieve it using the XRender functionality. XRender means rendering controls to client of the fly.
    http://examples2.ext.net/#/XRender/Basic/Add_Items/

    Here is a very simple example demonstrating the basics.

    Example
    <%@ Page Language="C#" %>
    
    <%@ Register Assembly="Ext.Net" Namespace="Ext.Net" TagPrefix="ext" %>
    
    <script runat="server">
        protected void Render(object sender, DirectEventArgs e)
        {
            this.PanelCenter.RemoveAll();
            
            Ext.Net.Label label = new Ext.Net.Label(DateTime.Now.Second.ToString());
    
            label.AddTo(this.PanelCenter);
        }
    </script>
    
    <!DOCTYPE html>
    
    <html>
    <head runat="server">
        <title>Ext.NET v2 Example</title>
    </head>
    <body>
        <form runat="server">
            <ext:ResourceManager runat="server" />
            <ext:Viewport runat="server" Layout="BorderLayout">
                <Items>
                    <ext:Container runat="server" Region="West" Width="150">
                        <Items>
                            <ext:Button runat="server" Text="Render new content" OnDirectClick="Render" />
                        </Items>
                    </ext:Container>
                    <ext:Panel ID="PanelCenter" runat="server" Title="Center" Region="Center">
                        <Items>
                            <ext:Label runat="server" Text="Some Initial Content" />
                        </Items>
                    </ext:Panel>
                </Items>
            </ext:Viewport>
        </form>
    </body>
    </html>
    Another approach is using a Loader.
    http://examples2.ext.net/#/Loaders/C...Direct_Method/
    http://examples2.ext.net/#/Loaders/C.../Http_Handler/
    http://examples2.ext.net/#/Loaders/C...ON_WebService/

Similar Threads

  1. Common ExtraParams for all DirectEvents
    By wdk in forum 1.x Help
    Replies: 7
    Last Post: Apr 05, 2012, 2:26 AM
  2. [CLOSED] Common Direct Methods
    By speedstepmem3 in forum 1.x Premium Help
    Replies: 3
    Last Post: Nov 25, 2011, 5:54 AM
  3. Replies: 1
    Last Post: Sep 12, 2011, 4:19 PM
  4. Replies: 0
    Last Post: Jun 02, 2010, 6:31 PM
  5. Common Ajax event arguments interface
    By tdracz in forum Feature Requests
    Replies: 0
    Last Post: Feb 24, 2009, 8:34 AM

Tags for this Thread

Posting Permissions