Questions tagged as 'jquery'

1
answer

Advantages JQuery versus Javascript

First of all, I do not want this question to be answered by opinion and therefore not be considered as such by the moderation of the community. All of us who have used or used JQuery know that once you make the structure of the library...
asked by 10.10.2016 / 00:28
2
answers

Delete select option without intervening a div

I have this code in PHP that repeats me 10 times the same select with the same information. for ($i=1; $i < 11; $i++) { $output.=' <div class="form-group"> <label>Prioridad '.$i.' de horario</label>...
asked by 08.07.2017 / 20:56
2
answers

Difference between currentTarget, delegateTarget and target in JQuery event

I have this simple script that captures a one-button event with jQuery: $(function() { $('#myButton').click(function(evt) { console.log(evt); }); }); <script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery....
asked by 24.12.2015 / 19:44
2
answers

How do I place the optgroup text before the option when selecting it with select2?

What I intend to do is that when selecting one of the options, put the parent text (optgroup) and show me something like " LG / Lg - Test 1 " (notece in the example that I say that "LG" is the parent (optgroup) and "Lg - Test 1" is the child (op...
asked by 09.05.2017 / 20:56
2
answers

obtain value of row of selected checks

I have an html table and in each record I put a checkbox How could I do so that when I select some records with the checkbox I get the data of the row to send them through a form? $(document).ready(function(){ $("input[type=checkbox]:ch...
asked by 01.08.2016 / 18:14
2
answers

Select tr of a table with javaScript if it has a text

I am trying to change the style of an entire specific row if, within that row, an element contains a plain text that I receive through a parameter in the url. With this code I extract the variable hidden in the url. var query = window.locat...
asked by 16.08.2016 / 00:43
1
answer

Get answer through ajax

I have a hypothetical problem : Mipagina.php <?php if(isset($_GET['nombre']) && !empty($_GET['nombre'])) :?> <?php $nombre = $_GET['nombre'];?> Hola <?php echo $nombre;?> <?php else:?> <form...
asked by 19.08.2016 / 18:48
2
answers

jQuery simulate a continue in a $ .each for

If I have the following code Arreglo.each(function() { if(micondicion) return false; } Exits the cycle, How can I continue with the next one?     
asked by 29.12.2015 / 17:30
1
answer

How to replace contents of an array with elements of another array JQUERY

I have a question about whether it is possible, and if it is possible, how can you replace content in an array, by the content of another array. For example: Input: "blue red and green" find = ["azul", "rojo", "verde", "y"] replace...
asked by 19.03.2018 / 19:38
2
answers

How to hide an html element without losing its space on the screen?

What I want to achieve is to keep some labels hidden either through its clase or its ID , what I'm trying to achieve is a accordion dynamically in horizontal format. If I click on any accordion this should hi...
asked by 26.01.2017 / 22:02