PDA

View Full Version : [SOLVED] dont work whit ie



olvap
11 May 2009, 7:51 AM
i have this code

var simple = new Ext.FormPanel({
labelWidth: 125,
bodyStyle:'padding:5px 5px 0',
width: 310,
defaultType: 'textfield',
items: [{
labelWidth: 100,
width: 100,
fieldLabel: 'Calle',
id: 'calle'},
{
labelWidth: 100,
width: 100,
fieldLabel: 'altura',
id: 'altura'}
,datefield
,combo
],
buttons: [{
text:'Mostrar',
name:'mostrar',
id:'mostrar',
handler: function(){
var dir=simple.getComponent(altura).value+" "+simple.getComponent(calle).value+", Santa Fe, Santa Fe, Argentina";
alert(dir);
}
}]
});

The variable 'dir' is null whit EI.
works whit mozilla.

there is the web page. www.olvap.com.ar/farmacia

Animal
11 May 2009, 7:56 AM
Read your code.



var dir=simple.getComponent(altura).value+" "+simple.getComponent(calle).value+", Santa Fe, Santa Fe, Argentina";


Are these two variables defined anywhere that we can't see?

olvap
11 May 2009, 8:01 AM
i guess not. how do i have to do to use the value of the textfields 'calle' and 'altura'?

olvap
11 May 2009, 8:20 AM
ok, thanks animal, i did ti, i defined these variables and change this
var dir=simple.getComponent(altura).value+" "+simple.getComponent(calle).value+", Santa Fe, Santa Fe, Argentina";

fot this
var dir=altura.getValue()+" "+calle.getValue()+", Santa Fe, Santa Fe, Argentina";