Questions tagged [form-fields]
224 questions
192
votes
9 answers
Adding asterisk to required fields in Bootstrap 3
My HTML has a class called .required that is assigned to required fields.
Here is the HTML:
126
votes
11 answers
How to turn off HTML input form field suggestions?
By suggestions, I mean the drop down menu appear when you start typing, and it's suggestions are based on what you've typed before:
For example, when I type 'a' in title field, it will give me a ton of suggestions which is pretty annoying.
How can…

Joseph
- 1,676
- 2
- 10
- 20
59
votes
17 answers
(Flutter) TextFormField Change labelColor on Focus
I am trying to change my labelText color when focused. I can change the text color but not when focused.
I have tried all the hint text colors and label text colors, but nothing helps.
Container(
padding: EdgeInsets.fromLTRB(15, 10, 15, 0),
…

Bnd10706
- 1,933
- 5
- 24
- 39
43
votes
9 answers
How to add class, id, placeholder attributes to a field in django model forms
I have a django model like below
models.py
class Product(models.Model):
name = models.CharField(max_length = 300)
description = models.TextField(max_length = 2000)
created = models.DateTimeField(auto_now_add = True)
updated =…

Shiva Krishna Bavandla
- 25,548
- 75
- 193
- 313
21
votes
3 answers
jQuery: find input field closest to button
I have a large HTML form with multiple input fields (one in each row).
Among these I have several fields with a specific class that appear left from a button.
There are no other buttons or fields in these rows so they only contain the field and…

user2571510
- 11,167
- 39
- 92
- 138
11
votes
1 answer
Angular 2+ set standard Form field appearance value
Working actually on form fields, I'm only using an outline appearance for my inputs (see more here).
Not wanting to copy appearance=outline everywhere on each form, I wanted to know if there was a way to set the standard value of the appearance on…

Joël-Etienne
- 386
- 1
- 12
8
votes
2 answers
Conditionally show and hide a form field and set the field value
I have a form in my Django that looks something like this:
class PersonnelForm(forms.Form):
"""
Form for creating a new personnel.
"""
username = forms.RegexField(
required=True, max_length=30, label=_("Name")
)
…

Mridang Agarwalla
- 43,201
- 71
- 221
- 382
8
votes
4 answers
Django Float Field input
Which is the best way to create a django form field that accepts floats and has the same functionality as a NumberInput? What I mean with same functionality is that django's NumberInput has arrows right next to the input that can increase or…

Alejandro Veintimilla
- 10,743
- 23
- 91
- 180
7
votes
3 answers
Passing array via hidden fields to rails
i have a hidden_tag like this in my form
<%= f.hidden_field :loc , {:multiple => true} %>
which renders to

RameshVel
- 64,778
- 30
- 169
- 213
5
votes
3 answers
Flutter TextFormFields clear when dismissing keyboard
Pretty much what I describe in the title. I have a pile of TextFormFields populated from Firebase when the app launches.
The user should be able to update these, and when they are done, click a submit button to update the database. The…

Bisclavret
- 1,327
- 9
- 37
- 65
5
votes
4 answers
Prevent Browsers not to remember password
We have an application with a login screen which has input field text and password. What I am trying to achive here is;
Prevent browsers to ask if, user wants it to be memorized by
browser.
Prevent all browsers not to memorize that field at any…

Demeter Dimitri
- 608
- 8
- 17
5
votes
2 answers
JavaScript Library with Bluebeam
I'm looking for some information/references/examples and how to use javascript in Bluebeam.
Bluebeam said that you can refer to the following AcroForm documentation…

Auredor
- 51
- 1
- 6
5
votes
3 answers
How can I put the asterisk of my required field on my label? (Symfony form)
I am working on Symfony 3 and I have some trouble with my form.
When I create a Symfony form with a field not required, here is my code :
I create the form :
$form = $this->createFormBuilder()
->add('prenom' TextType::class, array(
'label' …

Mickaël Leger
- 3,426
- 2
- 17
- 36
5
votes
2 answers
How to add custom class to label in Yii2 form field?
I want to add a custom class to label tag in this code in Yii2, but I don't know how.
= $form->field($model, 'name',[
'template' => "{label}\n
{input}
\n{hint}\n{error}"])->textInput(['maxlength' =>…
hd.
- 17,596
- 46
- 115
- 165
5
votes
3 answers
Use Sonata Field Type on normal Form Class
I'm trying to insert custom sonata form field type on the front page, not in SonataAdmin, something like this:
$form = $this->createFormBuilder($content)
->add('titleEs', 'text', array('required' => true, 'label' =>…

Borja Pombo
- 525
- 1
- 7
- 30