pstein Posted October 28, 2013 Share Posted October 28, 2013 (edited) Assume in multiple textareas appear some source code text whose number of lines varies from textarea to textarea. Is there a CSS style which I can attach to such a textarea and which tells the browser: "make textarea automatically big (height) enough to show ALL lines in textarea + 1 blank line at the end but NOT bigger/heigher/more rows than necessary? If this is not possible with CSS then at least is there a javascript command which let me calculate the number (and assign the "row" parameter to the textarea? If lines are longer then current textarea width/columns then these lines should be wrapped. Peter Edited October 28, 2013 by pstein Link to comment Share on other sites More sharing options...
davej Posted October 28, 2013 Share Posted October 28, 2013 When you say "textarea" do you mean an input textarea or do you mean a div? Link to comment Share on other sites More sharing options...
pstein Posted October 28, 2013 Author Share Posted October 28, 2013 (edited) input textarea or as HTML: <textarea ...> ... </textarea> Edited October 28, 2013 by pstein Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now