Ext JS JavaScript DHTML




Hello World Window







Ext.onReady(function() {
    var data = {
        name: 'A',
        company: 'B',
        city: 'D',
        state: 'E'
    };
    var p = new Ext.Panel({
        title: 'Title',
        width: 300,
        html: 'html code here',
        tbar: [{
            text: 'Template',
            handler: function(){
                var tpl = new Ext.Template(
                    'Name: {name}',
                    'Company: {company}',
                    'Location: {city}, {state}'
                );
                tpl.overwrite(p.body, data);
                p.body.highlight('#00ff00', {block:true});
            }
        }],
        renderTo: Ext.getBody()
    });
});