text input field size
text input field size
Lapointe
Posts: 430Questions: 81Answers: 4
Hello
Setting size in text field attr does nothing on editor form..
How to limit displayed length of input field as defined size ?
Else, is there a way to define default return action in editor size to goto next input in the form (like tab key) ?
Thanks for advance
This question has an accepted answers - jump to answer
This discussion has been closed.
Answers
Hi @Lapointe ,
You can use
maxlength
as in this example - see theage
field.Cheers,
Colin
Thanks
maxlength limit number of characters, but do not set the input size in the form...
a text field (255) is shown as big as a text field (5).
input size attribut set the input length, not the maxlength, but does not work in edit form.
The visible width of the input element is defined by CSS. You could use, e.g, the following to override for a specific field:
Here is Colin's example with that addition: http://live.datatables.net/batavisa/2/edit
Allan
Hello Allan, Colin
Exact. Colin did give me this example but I don't remember the field was displayed so small...
Thanks again
Hello,
{ "label": "Duyuru Tipi:", "name": "duyuru_tipi", "type": "select", "def": "Metin", "options": [ "Metin", "Link" ], attr: { style:"width:175px" } },
attr: { style:"width:175px" } add .js field and all style use