I have to be dead. I get damn exact alignment of numbers in the input field.
.number { text-align: right; } <input name="price" type="text" class="number" />
has no effect.
I need to use an input field, as I refer to the value in JavaScript, and I use it for both input and display.
thanks
You might have a more specific selector that overrides a property text-align .number
text-align
.number
To make your selector more specific, specify the element type ...
input.number { text-align: right; }
You may need to get more specific information, for example ...
#formId input.number { }
Yes - it text-align: rightshould work.
text-align: right
Are you sure that there is no other style or something that redefines it?
( , FireBug Firefox: "Inspect Element" - , , .)
If you still can't get this class to override styles that go elsewhere, you can also try
text-align: right! important;
Source: https://habr.com/ru/post/1718201/More articles:Flow control in a stream. - pythonРепликация с MySQL на MS SQL - sqlCreate page without posting .php at the end? - securityHTML left and right alignment elements - htmlSome data resilience - javaDifferent object with the same identifier - grailsСсылки гиперссылки в документе Latex начинаются с начала страницы - indexingPython code does not work properly when I run a script as a windows service - pythonAnything comparable to Visual Basic for use on Ubuntu? - ubuntuJMS CreateQueue Question - javaAll Articles