Questions tagged as 'javascript'

1
answer

Infinite scroll + tooltips

I'm trying to implement a page with infinite scroll and add tooltips to some items. Infinite scroll works fine, but tooltips only appear on the first page, before adding new items with the scroll. This is the example: link The toolti...
asked by 25.10.2018 / 10:35
1
answer

Doubt with functions in javascript, react js

because when I put a function in this way, the this.state , is not bringing me the values that happened when I write in the input fnLogin(event){ debugger; event.preventDefault(); this.setState(obtenerToken(this.s...
asked by 16.11.2018 / 20:12
1
answer

How to do smooth scrolling towards an element

I am looking for a way to scroll towards an element with a smooth animation. For this I have helped with this site . function scroll() { const a = document.getElementById("p"); a.scrollIntoView({ behavior: "smooth...
asked by 21.07.2017 / 22:32
1
answer

How to restart a javascript object

I have a variable that holds an object var gData = {}; class to create the object class Automate{ constructor(){ this.nodes = []; this.links = []; } } instancio and create a new object var automateObject = new Automate(...
asked by 06.04.2018 / 12:35
1
answer

How to give effect of flipping letter with css3

Good evening, I try to make an effect of flipping a letter, but when I do it my rear image appears to me the other way around, I have this code. .flip{ position: relative; transition: all 1s ease; transform: perspective(600px);...
asked by 04.11.2016 / 08:47
1
answer

Problems with button of google design material

I have a button to upload images in my web project; in Chrome and Microsoft Edge it works, but in Firefox it does not. Clicking should open the window to find the image to upload as it does in other browsers. My HTML code: <button...
asked by 29.03.2016 / 02:14
3
answers

Mask input text javascript

I want to mask an input text with the following format: Aa-1234, where the 2 letters are the acronyms of US states, separated by a hyphen, and the 4 numbers are the 4-digit zip code: how Could I do with javascript?     
asked by 20.07.2016 / 23:54
3
answers

___ ___ erkimt How hidden an entire column in a table with javascript / jquery? ______ qstntxt ___

I want to show / hide a column of a table using javascript / jquery .

Pressing a button shows or hides the entire column. The name of the column is on TH identified by an id I have achieved this by adding a class to each TD but I do not like this solution, I would like to achieve it without adding so much class attribute.

%pre% %pre%
    
______ azszpr135702 ___

Without so much code can be fixed by putting 1 button, instead of 2.

Unless it's strictly necessary, I think it's better if you only have one button, that you make %code% that commutes the visibility of the column.

To do this, we select the header with %code% and hide it or show it with %code% .

To hide / show the rows, we can make a small filter like this:

%pre%

which means: Take the %code% that are your father's third child. The parent is the row %code% and the third child is the %code% in the Country column.

and to them you apply the %code% as well.

With this you save putting the %code% to each element you want to hide.

%pre% %pre%
    
______ azszpr135706 ___

To hide with %code% , without Jquery, it occurs to me that since you already have a class that identifies you, you can use them to add a class %code% , for example.

%pre% %pre% %pre%

If you also take into account the modification of %code% , you could delete the classes of each %code% and only add a %code% to the table as well as remove a button and have only %code% that works as a %code% , but all only with only %code%

%pre% %pre% %pre%
    
______ azszpr135708 ___

You can also do the following from CSS:

%pre%

Or have a class hide in CSS and by means of javascript, add the class:

%pre%     
___

I want to show / hide a column of a table using javascript / jquery . Pressing a button shows or hides the entire column. The name of the column is on TH identified by an id I have achieved this by adding a class to each TD but I do not...
asked by 02.02.2018 / 12:15
2
answers

Advantages of using const on var in JavaScript

In javascript I can declare a constant in the following two ways: const CONSTANTE = 'soy una constante'; var CONSTANTE = 'soy una constante'; Of course, using const instead of var makes the code more understandable but,...
asked by 08.01.2016 / 09:09
2
answers

hide javascript element nobr

I have this <tr> <td nowrap="true" valign="top" width="190px" class="ms-formlabel"><h3 class="ms-standardheader"> <nobr>Estado</nobr> </tr> <tr> ... ... ... </tr> <tr> ......
asked by 22.10.2018 / 12:18