İçereği Atla
Menü
Bu soru işaretlendi
3 Cevaplar
16907 Görünümler

How to insert line break in placeholder in text area field?

 

Avatar
Vazgeç

Hello ,

You get any solution because i am facing similar problem.

En İyi Yanıt

I am surprised no one came up with a working solution in the last 9 years.

You can simply add & # 1 0 ; (without spaces) to your placeholder text, browser will register it as line feed.

Avatar
Vazgeç
En İyi Yanıt

Is it possible ?? ;) Have you tried \n \r ?

Avatar
Vazgeç
Üretici

yes tried that didn't work.

En İyi Yanıt

Only by formatting with multiple spaces, e.g.:

1st line of placeholder starts here                                         2nd starts here            etc    

If the size of textarea is fixed, browsers will show such long texts as if they were on multiple lines.

You'll have to fine-tune the number of spaces to make placeholder text look as you like.

Avatar
Vazgeç
İlgili Gönderiler Cevaplar Görünümler Aktivite
1
Tem 16
4295
0
Tem 16
5185
1
Ara 15
3736
1
Kas 15
5186
1
Oca 24
15720