简体   繁体   中英

How can i align the text to right side in Textbox in Javascript… ??? By default it is left-align

My problem is that i couldn't align the text in the textbox from the right side...

Generally this kind of align are used in Calculator... where digits are align from the right side...

i want to do this in HTML by using javascript....

<input type="text" style="text-align: right" />

should work.

Other interesting attributes are: direction:rtl;unicode-bidi:bidi-override;

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM