Reputation: 339
I have a php page how can i show another window using extjs? So code i have so far is like this:
Can anyone show me how can this be done? I only want this done by extjs please dont tell other alternatives.
<script type="text/javascript" charset="utf-8" src="http://cdn.sencha.io/ext-4.0.2a/ext-all.js">
</script>
<script>
window = new Ext.Window({layout: 'border'}).show()
</script>
Upvotes: 0
Views: 441
Reputation: 338
Bellow is the code to show an Ext window. Tested and it is working.
<link rel="stylesheet" type="text/css" href="http://cdn.sencha.io/ext-4.0.2a/resources/css/ext-all.css" />
<script type="text/javascript" src="http://cdn.sencha.io/ext-4.0.2a/ext-all.js"></script>
<script type="text/javascript">
Ext.onReady(function(){
var window = Ext.create('Ext.Window',{
title: 'Hello',
height:100,
width:100
});
window.show();
})
</script>
Working on jsFiddle
Upvotes: 1
Reputation: 14873
new Ext.Window({
title:'Hello World Window',
html:'Am I the right size?',
height:Ext.getBody().getViewSize().height,
width:Ext.getBody().getViewSize().width*0.8 //80%
}).show();
ExtJS open window with max height
Upvotes: 0