PDA

View Full Version : stop page load



borden0108
22 Oct 2011, 4:16 AM
hi all,

i have a asp file on a server that i am accessing (i just need to log in so that i can access data behind the logon) that redirects from the current page to the internal home page after a user logs in, however this does the same with my app and goes out of the app to the internal home page. is there anyway to stop this from the client side.

here is the relavant code ( it stops after authfrom.hide on line 60 and redirects).



var calculateDesiredWidth = function() {
var viewWidth = Ext.Element.getViewportWidth(),
desiredWidth = Math.min(viewWidth, 400) - 10;
return desiredWidth;
};




authform = new Ext.form.FormPanel({
id: 'infomation',
layout: 'fit',
method:'post',
centered:true,
url:'https://intranet.trinity.vic.edu.au/CookieAuth.dll?Logon',
width: 400,
standardSubmit : true,
scroll:'vertical',
floating: true,
modal: true,
height:300,
items:[{
xtype: 'fieldset',
width: calculateDesiredWidth,
title: 'Login',
instructions: 'Please complete the information.',
items: [{
name: 'username',
label: 'username',
xtype: 'textfield',
cls:'form-height',
},{
name: 'password',
label: 'password',
xtype: 'passwordfield',
cls:'form-height',
},{
xtype: 'hiddenfield',
name:'curl',
value:'Z2Fdefault.asp',
}],
}],
dockedItems: [{
dock: 'top',
xtype: 'toolbar',
title: 'Intranet Login'
},{
dock: 'bottom',
xtype: 'toolbar',
items: [{
text: 'Cancel',
handler: function() {
authform.hide();
}
},{
xtype: 'spacer'
},{
text: 'Submit',
ui:'confirm',
handler: function() {
authform.submit ({
waitMsg:'Submitting',
success: function(e) {
authform.hide()
}


});
},
}],
}]
});









Thanks Matt