Questions tagged as 'javascript'

2
answers

Insert Option with javaScript

I have a dynamic form. With a radiobutton field and a select . According to the value that I select in the option I populate the field list with values selected. Example. Option 1 Option 2 When you select option 1, the select fie...
asked by 19.10.2018 / 19:36
3
answers

How to make a text stay one color, and return to the original?

I'm trying to make an "online" system, offline When the user clicks "• Online", where the ball is green, it turns red, and the text updates to "• Offline " I searched, tried, did not find and could not do ... What I did was this: <a hr...
asked by 22.08.2018 / 00:01
1
answer

How to change the class of a button according to its id and value?

I want to modify the class of a button according to its id and its value. Each <button> has equal identifiers, but different values. I have tried this way below, however only the first button is modified, regardless of the value...
asked by 27.01.2017 / 15:43
2
answers

Text suggestion [closed]

I'm creating a form and would like to know some way where I start typing a word and it starts to show me suggestions, identical as does the travel shopping at the airport or at various websites     
asked by 27.04.2017 / 15:45
3
answers

Hide field required and not required

I have a form. In this form I have two radiobutton with two options. 1) Questao 1 (Obrigatorio) 1 = Sim 2 = Nao ______________________ 2) Questao 2(Obrigatorio) 1 = Vivo 2 = Morto If this question 1 is = Yes Question 2 loses the oblig...
asked by 14.02.2017 / 19:12
3
answers

Get the site name in url in javascript

Well, I have the following: I can have the following situations from a url: www.example.com or link or link and also with HTTPS. I would like to take only the word "example". But I do not know where to start because you can have several situ...
asked by 23.02.2017 / 19:34
3
answers

Adding html with jquery

Good when I want to add an html to the page using jQuery I do this: $("body").html('ddd'); But in this way I delete the old content, can I add the html in the Body without deleting the content of the page?     
asked by 16.12.2016 / 20:02
2
answers

Load button more using list (li) [duplicate]

Well, I need some help. I have a list in the following structure. <ul> <li>TESTE</li> <li>TESTE</li> <li>TESTE</li> <li>TESTE</li> <li>TESTE</li> <l...
asked by 16.01.2017 / 17:32
4
answers

Return True or False in jQuery Success

< script type = "text/javascript" > $(document).ready(function() { $('#btnEnviarDados').click(function() { var strFomr = $("form").serialize(); $.ajax({ url: $("form").submit(), type: "POS...
asked by 07.02.2017 / 01:48
2
answers

Split in reverse order

var itens: "101|102|103|104"; var quebra = itens.split("|"); for (var i = quebra.length - 1; i >= 0; i--) { var unidade = quebra[i]; $("#lista").append("<p>" +getValue(unidade, jsonTitles)+"</p>"); } The result of this...
asked by 24.03.2017 / 18:04