I need to create a fixed size (height and width) text area or box in a HTML page. This area will be filled with responses from Ajax requests. Some of these responses will be too big to fit within this area, therefore, some scroll bars should be displayed. Nice to have (but not must have), users should be to select the content of the box.
How to achieve this best in HTML? It seems like textarea could be a solution, but how do I work with height and width rather col and rows? If possible, I would like to avoid having to use a form just for this textarea. Should I use a separate Javascript/Jquery library instead?
I am looking for code examples to design/implement this box. Thanks.
You could do
and add some CSS style
do you already have the code to populate the text area with the Ajax response?