Tuesday, December 6, 2011

How to make an input text box without horizontal scrolling?

I have a text input area which forms a horizontal scrolling bar at the bottom when the text reaches its end. Instead of the text continuing on the same line which is what happens now, I want the text to go on to the next line and so on and no scrolling bar to appear. How can I achieve this?|||You can either use TEXTAREA or INPUT. TEXTAREA gives you the flexibility to display a larger box.





%26lt;TEXTAREA name=scroll cols=x rows=y readonly%26gt;


%26lt;INPUT type=text name=scroll value=""%26gt;





If you don't want the scroll bar to appear, then clear the value of the textarea before you add the next line of text.





Then use javascript to define an array and cycle through the array adding each element to the input tag.





document.form[0].scroll.value = array[x];|||simple scrolling text generators choose your own color http://www.kaleeko.com/pages/f鈥?/a>

Report Abuse


|||%26lt;div style="width:120;height:120;overflow: auto; overflow-x: hidden; border: 1px solid"%26gt;


Text Goes in here!%26lt;/div%26gt;|||Or you could code it at the application level and force the object to not have a scrollbar, assuming this is Java/.NET.

No comments:

Post a Comment