cancel
Showing results for 
Search instead for 
Did you mean: 

a text area every moment i edited dynamically the scroll bar goes to the top. i know it is not a problem with the website because it works with other browsers

SOLVED
Highlighted
New Contributor

a text area every moment i edited dynamically the scroll bar goes to the top. i know it is not a problem with the website because it works with other browsers

there is a problem with the scroll bar of a text area. whenever it is edited dynamically the focus area moves to the top instead of holding the focus in the area of the new inserted text. even if i move it down by hand it goes up again.

1 ACCEPTED SOLUTION

Accepted Solutions
New Contributor

Re: a text area every moment i edited dynamically the scroll bar goes to the top. i know it is not a problem with the website because it works with other browsers

ok i fixed by code in my program. when i finished editing, i use this code in javascript. document.getElementById("chatMainTxt").scrollTop=document.getElementById("chatMainTxt").scrollHeight;

3 REPLIES
Legendary Contributor

Re: a text area every moment i edited dynamically the scroll bar goes to the top. i know it is not a problem with the website because it works with other browsers

here's a way to make scrolling more pleasant:

1. Start Firefox.

2. Click Tools, Options.

3. Click the Advanced icon, then look in the Browsing section.

4. Enable Use smooth scrolling, then click OK.

New Contributor

Re: a text area every moment i edited dynamically the scroll bar goes to the top. i know it is not a problem with the website because it works with other browsers

its already activated. My problem is that when i try to edit the text area dynamically it refreshes and goes to the top

New Contributor

Re: a text area every moment i edited dynamically the scroll bar goes to the top. i know it is not a problem with the website because it works with other browsers

ok i fixed by code in my program. when i finished editing, i use this code in javascript. document.getElementById("chatMainTxt").scrollTop=document.getElementById("chatMainTxt").scrollHeight;