Most voted "input" questions
It is an input element that represents a typed data field, usually as a form control to allow the user to edit or enter data.
Learn more…466 questions
Sort by count of
-
28
votes4
answers62720
viewsHow to style a "file" input?
I have this structure: <section id="cadastro" class="cadastroVersao pg-i"> <div class="titulo"> <h1><i class="icon-clientes"></i>Cadastro de versão</h1> <a…
-
23
votes8
answers44013
viewsHow to remove auto complete input from google Chrome?
I want to remove yellow background when this enabled auto complete from Google Chrome. I tried to disable auto complete by applying: autocomplete="off" and I was unsuccessful. The top image is the…
-
16
votes2
answers1206
viewsShould placeholders contain examples or descriptions?
I am building an application and in my forms the placeholders fields are empty because I haven’t decided which criteria to use to fill them. On many websites and apps it is common to find two types…
-
14
votes1
answer1507
viewsFocus, when starting the page
How best to get an element to focus as soon as the page loads
-
13
votes4
answers2688
viewsHow to add the ninth digit, fixed, using jQuery Mask?
How to add the ninth digit, in a fixed form, using the jQuery Mask? $('#telefone').mask('(00) 90000-0000'); This way I use is only optional.…
javascript jquery input mask jquery-mask-pluginasked 9 years, 6 months ago Marcelo de Andrade 7,261 -
12
votes3
answers6427
viewsStyle input type='number' to change arrows
How to customize the input type='number' as the image below? Click on the +/- sum or subtract the number inside the box. Currently my code is: .bedrooms = f.input :bedrooms, :label => false, as:…
-
11
votes2
answers680
viewsIn HTML what is an Undetermined Checkbox and how to use this status along with CSS?
As far as I knew a input of the kind Checkbox could have three states, checked, unchecked and disabled. But it seems he has a fourth state which is the undetermined. See in the image a comparison of…
-
10
votes1
answer338
viewsWhat is the purpose of the "Image" input?
Only now have I realized these days that there is one input with the attribute type equal to "image". I saw this being used on some site (very old by the way) to submit a form. I have the following…
-
9
votes3
answers94464
viewsHow to mask an HTML5 input?
For example... I want one input unique to phone numbers. By typing the DDD it automatically receives the parentheses: (xx). When typing the rest of the numbers it divides with a hyphen, for example:…
-
8
votes1
answer691
viewsInput Date type with year containing 6 digits
Look at the snippet just below, that the input of the kind date when typed in the value year, it is possible to insert 4, 5 or 6 digits to be exact: <input type="date"> My doubts are exactly:…
-
7
votes1
answer478
viewsWhat is the security in using input "password" or "text"?
Recently we are on a wave to use the combination of input of passwords with the option to hide/display the password (*** -> abc), with the "eye" technique. I understand this purpose as it greatly…
-
7
votes1
answer570
viewsHow to prevent an Input Required from starting with the CSS style :invalid
When I have a input required that has some CSS style when it is :invalid, even before the user interacts with the input it is already stylized as invalid. How can I avoid this? Take the example:…
-
6
votes4
answers1051
viewsIs it possible to change Placeholder in Focus with CSS?
Imagine I have one input to the phone number, but that when the user focuses on it I want to change the text of the placeholder, for example of "telephone" for "only numbers". You can do this with…
-
5
votes2
answers55591
viewsLimit html input
I want to put an input in html and I want to limit only to 2 numbers. <input type="text" name="Dia" maxlength="2" size="2" > I tried this but still letters appear.…
-
5
votes2
answers5706
viewsPassword check
Hello, I’m starting to learn Javascript and I’m not being able to validate my code if there are 3 characters in uppercase, 2 numbers and 1 special character in my input. I would like to know what I…
-
5
votes3
answers3914
viewsHow to put the value of a PHP variable inside an input?
How to put the value of a variable (already calculated in PHP) inside a input? <form method="post" action="calculos.php"> <div id="circulantes"> <div class="ativocirculante"…
-
5
votes1
answer137
viewsWhy does FILTER_SANITIZE_EMAIL not remove some special characters?
I know how the FILTER_SANITIZE_EMAIL works, but what I can’t understand is why it doesn’t remove the following characters: ! # $% & '* + - =? ^ _ `{|} ~ @. [] . I know that in the documentation…
-
4
votes1
answer1007
viewsPass Javascript variable to PHP body
I’ll try to get as much detail as I can about my problem. I have an HTML select that pulls your options directly from the database, as per the code below: $conn = new mysqli('localhost', 'root', '',…
-
4
votes1
answer214
viewscustomize input for multiupload images
How can I customize a file input field for multiupload images? would like to get some information from the image, such as: format, size. (I know there are several plugins for this, but I would like…
-
4
votes2
answers1955
viewsWhy is the initial state of a required <input> invalid?
When I place one or more restrictions on one <input>, initially its state appears as invalid. As in the example below: input { border: 2px solid #ccc; padding: 8px; } input:invalid {…
-
4
votes1
answer8622
viewsHow do I get in the Input file?
I need to send several attachments via Phpmailer and am using jQuery to get the value of input file, now I need to pick up the file path to be able to send by email, but when I take the path it…
-
4
votes1
answer1335
viewslimiting the value that can be entered in the input
I have a php variable that has a value that varies depending on the moment!! Example 1st moment $valor = 300 second moment $valor = 20 3rd moment $valor = 5300 fourth moment $valor = 1300 I also…
-
4
votes2
answers634
viewsHow to Remove Input Image Edge
I’m wearing a input image to work as a favorite button <input type="image" class="btnFav" title="Favoritar" /> Only he gets a square edge on him I’ve tried using the css down, but nothing…
-
4
votes1
answer2415
viewsHow to take the button out of an input file (without JS)
I got the following input file and wanted to know how to remove the button, so that in the box show only the name of the file *It is not necessary JS, I have seen some examples and remember that…
-
4
votes1
answer55
viewsHTML5: Problem with operator not in the Pattern attribute of input text
I want to make input text allow only the following strings: site.com; site.com.br; site123.com123.br; site-123.com.br. But never: site-123-.com.br My expression was like this:…
-
4
votes5
answers16658
viewsinput only numbers with jquery
I have a function that validates typed characters and does not let the user use special characters but this same function does not work for numbers, someone knows some function in jquery to validate…
-
4
votes2
answers1564
viewsIs it correct to use the Input tag within a Label tag?
I was taking a look at the tutorial from W3schools, where he’s teaching to use the input of the kind checkbox in Bootstrap. According to one example, I saw the following code:: <div…
-
4
votes4
answers1757
viewsEmpty input cannot receive zero
I have a form with more or less 5 inputs, at any given time inputs will be worthless, and I want to find out what the lowest value between them, but whenever there is one or more inputs voids it…
-
4
votes2
answers9324
viewsSubtract days from an input date with javascript
I need to take a data from a type number field and add to a date of a input date. I already did, but now I need to get the result of that date and subtract 14 days, but I can’t get it. I’m a…
-
4
votes2
answers402
viewsHow to make a span display the value of a range as you move it with your mouse?
The function is working, but I want to update the value in <span> as I move the mouse. Someone can help? function mostrarPorcentagem(novoValor) {…
-
4
votes2
answers85
viewsFunction Optimization (probably with for loop)
I’m having trouble developing when we talk about for... The basics I can understand now in practice... People have developed this code and I believe it can be reduced to a few lines with for. Notice…
-
4
votes3
answers134
viewsExplanation of name in php
Could someone explain to me the difference and where I can change it.: $nome=$_POST['nome']; That one $nome I know it’s standard in case I use <input type="text" name="nome"> More in this…
-
4
votes1
answer527
viewsBlade OR syntax within Laravel Collective input value
The following input works normally, but when I pass it to the syntax of Laravel Collective, says that the variable $servico does not exist. It does not exist at all, so it should show the value…
-
4
votes3
answers1776
viewsDeselect radio type input
I have two inputs of the kind radio. Follow the code below: <input type="radio" id="isgift0" name="isgift" value="0" class="arredondado" /> <label for="isgift0">Teste 1</label>…
-
4
votes4
answers6855
viewsExecute function when losing focus of an input
I have a normal html input: <input type="text" class="form-control" style=" width: 20%" id="hLane1"> </input> To make it run an event just use the event click But what if I need to…
-
4
votes2
answers284
viewsIs it safe to leave crucial information in an Hidden input in HTML?
I can leave, for example, the ID of a user q I will do select in the hidden, and use it (the id) without having to confirm that that ID belongs to the logged in user? In other words, the user can…
-
4
votes2
answers555
viewshow to automatically fill in an input?
As the code shows with several textfield, I want to make visible only date, date and KM and from these 3 fill in the others that will be invisible, the amount to be paid will be displayed on an…
-
4
votes2
answers277
viewsIs it possible to use the resize function of the textarea in an input?
Good morning, everyone. I’m making a form, and I wanted to make a <input type='text' /> that the user could set the width, with that drag resize that exists in the textarea. I want to insert…
-
4
votes2
answers49
viewsHow to reload a page without losing inputfile
Hello, I have a PHP me code where I use simplexml_load_file to read an xml on this page I need to send a form with submit, My problem is that by sending this form xml data is lost. And I would like…
inputasked 3 years, 10 months ago willian algusto 43 -
3
votes5
answers59481
viewsTake content from within a Div and put in Input value
I have a form, and inside it I have an input, which will have to take what it contains inside a DIV, which in case is only text. The input is like this: <input class='formContato' type='text'…
-
3
votes2
answers8784
viewsVBA Set ie = Createobject("Internetexplorer.Application")
Next, I’m picking up from VBA to browse a web page (can be with Internet Explorer) Basically I found some codes with the Method CreateObject("InternetExplorer.Application"). However, I cannot input…
-
3
votes1
answer824
viewsSend multiple values in an input to PHP, using jQuery AJAX
I have a script to insert several items in a list of a form, using Ajax. For each element inserted in this list, a next one must be added. After inserting X elements, it should take all values and…
-
3
votes1
answer13146
viewsHow to put 2 inputs side by side?
How can I put 2 input aligned side by side? <li> <input type="text" /><input type="checkbox" /> </li>…
-
3
votes2
answers8009
viewsSet JS variable in input value HTML
I have several inputs in an HTML, where the Ids are correct. I want to search the value of these inputs with these Javascript variables, but only the nome takes the variable value! The rest of the…
-
3
votes1
answer1380
viewsClone Input text and pass the value of cloned input via POST
I need to clone an Input text by clicking on a "+" button and then pass the value of this cloned field via POST to the other form data... I’m using a Javascript function to make the clones…
-
3
votes1
answer83
viewsJava input problem
The inputs of my program are overwriting itself. It ignores the first and already Lanca the second straight. System.out.println("Digite o nome do passageiro"); String nome = in.nextLine();…
-
3
votes1
answer335
viewsGet the most selected radio input with Javascript
I’m putting together a test, I just have the html structure done, I wanted to know how to know which of the radio input is most selected. Ex.: Most selected was "A)" then when submitting the form,…
-
3
votes2
answers322
viewsDIV only clickable if RADIO is marked
I wish my <button id="bottaaoPA">Comprar</button> was only clickable if the radio were marked. Code: $(function(){ var contador = 0; $('.pa').click(function(){ if(contador === 0) {…
-
3
votes1
answer1288
viewsauto-fill input with jquery php
I would like to convert this code into jquery. To say. Instead of appearing in iframe, I would like it to be a single page normally, and the insertion is refreshless. $.post("resultado.php",…
-
3
votes1
answer928
viewsWhen clicking on a select item, show input
I want when I click the select "OTHER" to appear next to an input, but so far unsuccessful. My code HTML and JS: function mostraCampo( el ) { var outros = document.getElementById('outros'); if…