enter does not work in textarea in Internet Explorer 8

后端 未结 4 1242
长情又很酷
长情又很酷 2021-01-03 00:23

When I press enter in a textarea which has whitespace attribute is set to nowrap through css, it is ineffective. No new line is created. Instread a simple whitespace appears

4条回答
  •  南笙
    南笙 (楼主)
    2021-01-03 01:12

    The available options (found here: Quirksmode.org), are:

    • normal
    • nowrap, IE5.5+
    • pre, IE6+
    • pre-line IE8
    • pre-wrap IE8

    It might be worth using white-space: normal (I don't have IE with which to experiment, but I imagine that normal would be available by default if it's possible to alter the state to abnormal).


    Edited, with respect to the OP's comment/response.

    Are you using a doctype? (I recommend using )

    Assuming that you are, is there any chance you could post a link to a demo-page? Or perhaps post your (x)html and css, to see if there's some manner of style-override, or typo, preventing the css being applied?

提交回复
热议问题