JavaScript - Increasing Rows in a Text Area
From All n One's bxp software Wixi
Revision as of 14:05, 3 September 2015 by Philip Lacey (talk | contribs) (Created page with "= Overview = A text area is a special type of HTML object which is used for capturing large amounts of text. The challenge is that there is limited space on a web page. Th...")
1 Overview
A text area is a special type of HTML object which is used for capturing large amounts of text. The challenge is that there is limited space on a web page. There is a very easy way to make space dynamically change using the following capability.
2 Setup
We start with a text area in form. In this example... "Description"
We are going to edit the questions, using the details from the very top of the page.
We add some JavaScript to the onFocus and the onBlur of the question.
document.getElementById("strCDA_292_field_0_2").rows = "10";
You change the strCDA_292_field_0_2 to whatever your text area is.