lechuck
28 Jun 2007, 9:53 AM
That suppose to scroll the element to the bottom.
Ext.get('center-div').scroll('b', 0, true);
I use Ext.BorderLayout to create the layout and use prototype library to fill the div 'center-div'. But when I call scroll function it does not work.
This is the function that receive the Ajax response
getMessage:function(response)
{
if(response.responseText.blank() === false)
{
new Insertion.Bottom('east-div' ,'<hr>' + response.responseText.escapeHTML());
t = response.responseText.split('{||}');
for(var n=0; n < t.length; n++)
{
cols = t[n].split('{|}');
if(cols.length > 1)
{
var newid = cols[0].replace(' ', '');
member = cols[1];
if(newid != undefined && this.lastid.indexOf(newid) == -1)
{
new Insertion.Bottom('center-content' ,cols[2]);
this.lastid.push(newid);
new Effect.Highlight('pbcchat_'+newid);
Ext.get('center-div').scroll('b', 0, true);
}
}
}
}
}
Please any help with that?
I'm a newbie with Ext library
thanks
Ext.get('center-div').scroll('b', 0, true);
I use Ext.BorderLayout to create the layout and use prototype library to fill the div 'center-div'. But when I call scroll function it does not work.
This is the function that receive the Ajax response
getMessage:function(response)
{
if(response.responseText.blank() === false)
{
new Insertion.Bottom('east-div' ,'<hr>' + response.responseText.escapeHTML());
t = response.responseText.split('{||}');
for(var n=0; n < t.length; n++)
{
cols = t[n].split('{|}');
if(cols.length > 1)
{
var newid = cols[0].replace(' ', '');
member = cols[1];
if(newid != undefined && this.lastid.indexOf(newid) == -1)
{
new Insertion.Bottom('center-content' ,cols[2]);
this.lastid.push(newid);
new Effect.Highlight('pbcchat_'+newid);
Ext.get('center-div').scroll('b', 0, true);
}
}
}
}
}
Please any help with that?
I'm a newbie with Ext library
thanks