1. #1
    Ext User
    Join Date
    May 2008
    Posts
    13
    Vote Rating
    0
    edor is on a distinguished road

      0  

    Default How to display/load formPanel into Panel...?

    How to display/load formPanel into Panel...?


    hai all..
    i had build treePanel based on database. so the one of some callback from server is url.
    this url is linked to another extjs file (formPanel). the problem is i couldn't load that url's content to myPanel. somebody can help me...?
    here the scripts:
    HTML Code:
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
        <title>User Generated Content Module</title>
        <link rel="stylesheet" type="text/css" href="../ext-2.0/resources/css/ext-all.css" />
    
        <!-- GC -->
         <!-- LIBS -->
         <script type="text/javascript" src="../ext-2.0/adapter/ext/ext-base.js"></script>
        <script type="text/javascript" src="../ext-2.0/ext-all-debug.js"></script>
         <!-- ENDLIBS -->
        <script type="text/javascript" src="../ext-2.0/ext-all.js"></script>
        <link rel="stylesheet" type="text/css" href="../ext-2.0/examples/examples.css" />
        <!-- script language="javascript" src="hello.js"></script -->
    </head>
    <body>
    <script type="text/javascript">
    Ext.BLANK_IMAGE_URL = '../ext-2.0/resources/images/default/s.gif';
    Ext.onReady(function(){
        Ext.QuickTips.init();
        
        var Tree = Ext.tree;
        this.tree_1 = new Tree.TreePanel({
            title: 'news',
            rootVisible: true,
            autoScroll: true,
            containerScroll: true,
            margin: '5 0 0 0',
            loader: new Tree.TreeLoader({
                dataUrl: 'http://localhost/project/getTree.php?type=News'
            }),
            listeners: {
                click: {fn: nodeClick, scope: this }
            }    
        });
        root = new Tree.AsyncTreeNode({
            text: 'News Management',
            id: 'root'
        });
        this.tree_1.setRootNode(root);
        
        //root.expand();
        
        this.westPanel = new Ext.Panel({
            title: 'News Management',
            collapsible: true,
            frame: true,
            plain: true,
            width: 350,
            region: 'west',
            layout: 'accordion',
            layoutConfig: { animate: true },
            items: [this.tree_1]
        });
        
        this.centerPanel = new Ext.Panel({
            id:'centerPan',
            title: 'Detail',
            frame: true,
            plain: true,
            region: 'center',
            height: 300,
            //autoLoad: { url: 'node.attributes.url'}
            //html: 'this is my first Buddy'
        });
        
        this.panel = new Ext.Panel({
            title: 'Citizen Journalism',
            layout: 'border',
            frame: true,
            plain: true,
            height: 350,
            bodyStyle: 'background: white;',
            items:[this.westPanel, this.centerPanel],
            renderTo: 'bigPanel'
        });
        
        function nodeClick(node, e){
            if(node.attributes.url)
            {
                
                this.centerPanel.load(node.attributes.url);
            }
        }
        
        
    });
    
    
    </script>
    <div id="bigPanel"></div>
    </body>
    </html>
    thanks for all attention...
    regards
    Last edited by mystix; 4 Sep 2008 at 6:41 PM. Reason: moved to 2.x Help. also, post html in [html][/html] tags. see http://extjs.com/forum/misc.php?do=bbcode#html

  2. #2
    Ext User
    Join Date
    Jul 2007
    Location
    Florida
    Posts
    9,996
    Vote Rating
    5
    mjlecomte will become famous soon enough mjlecomte will become famous soon enough

      0  

    Default


    More info?

    I see you specified a url. So what's wrong? Errors? What do you see in firebug console as far as traffic?

  3. #3
    Ext User
    Join Date
    May 2008
    Posts
    13
    Vote Rating
    0
    edor is on a distinguished road

      0  

    Default


    if url's content is an ext.formpanel script, it display upon myPanel as a plain text like this:
    Ext.Msg.alert('Status', 'Changes saved successfully.');
    it should be display alert box not only plain text right..?!

  4. #4
    Ext User
    Join Date
    Jul 2007
    Location
    Florida
    Posts
    9,996
    Vote Rating
    5
    mjlecomte will become famous soon enough mjlecomte will become famous soon enough

      0  

    Default


    Not sure.

    Check panel.load() especially the bit about scripts. Depending on what you're doing maybe you want MIF extension?

Thread Participants: 1

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi