I am trying to change the color of the elements, changing their class, while the mouse is held down, giving the effect of "painting". Doing it by mouse clicks I have it, here I leave the code:
$(() => {
$('table').on("click", "td...
How can I copy the contents of a div (or any element) to the clipboard using JavaScript / jQuery only without using Flash?
For example, if I have this code:
<p id="mi_parrafo">
Texto que quiero copiar
</p>
<...
I would like you to help me to give css to the alert() and the confirm() of javascript, so that my messages are something elegant, I do not want to opt for a modal only for confirmations, so if someone knew how to I realize I would...
I would like to know how I can count the elements that exist with the same class in an HTML to be able to be with JQuery but with JavaScript also OK.
Thank you!
Example
div class="hola"
div class="hola"
div class="hola"
A s...
Currently I can only show / hide a single element like this:
$(document).ready(function () {
$("#Mostrar_Tabla").click(function () {
if ($("#Tabla_Mostrar").is(":visible")) {
document.getElementById...
I have a series of labels in my view JSP . Each label shows a unit of measure and if you want to edit it, it is replaced via javascript with a input via button.
NOTE: both the labels and the input are elements wit...
I'm trying to reuse ajax to make it more mobile in my project.
Put it in the following way waiting for an answer but no.
function _ajax(params,uri,type){
$.ajax({
url: uri,
type: type,
dataType: 'json',...
The idea is that if I have two HTML pages I can join them, and I can call their methods and the DOM between both pages, without using a controller like PHP
Example:
pagina1.html
<!DOCTYPE html>
<html>
<head>...
I am validating my form with formvalidation , the date is only Valid if I write it, if I choose it from the calendar, it is not valid. If you can help me validate it, I would appreciate your help. I use the datepicker from Jquery.
Form fie...
I'm designing an html table with Jquery which only edits the records or just cancels when editing, which starts my problem here. Simply wish is that by pressing the cancel button return the data to as they were before, for example:
In my tabl...