Questions tagged as 'javascript'

4
answers

Is there any way to detect if there is any asynchronous call being routed?

I need to loop asynchronous calls, but they can not run simultaneously, I have to wait for the end to run another. I just do not have control over this call ( It's a js function Sharepoint CSOM ). So I at the beginning of my idea is just to d...
asked by 26.01.2015 / 13:59
1
answer

Scope and IIFE in JS [duplicate]

Are the staff all right? I'm here with a question in a small code, basically I have a for loop that adds a click event to each number where the number that was clicked on the alert will be displayed, and of course the number presented is alway...
asked by 05.11.2015 / 22:01
1
answer

What is the gain of "unifying" the .css and .js resources of a site?

Scenario: A X site has 5 .css files and 5 .js files all with 5KB , a / strong> has the same HTML as the X site but its .css and .js resources are linked together (.js with .js and .css with .css) . Question: What is the difference...
asked by 06.11.2015 / 15:35
1
answer

Display and hide form fields of the radio type

I have a form with two inputs of type radio , one with individual and legal value. When one is selected, the fields to fill in are different from the other (especially in PJ), so I would like to know a very handy way to display and...
asked by 24.04.2015 / 21:28
1
answer

What would be javascript dynamic parameters? [closed]

What would be dynamic parameters in javascript?     
asked by 20.10.2015 / 21:54
1
answer

How to create expression to allow only a few characters?

I am creating an input where an onKeyUp checks the entered characters, it should validate the following: Maximum number of characters The first digit should be just numbers [0-9] The code is composed of alphanumeric digits and only the /...
asked by 23.10.2015 / 19:58
1
answer

How to traverse attributes of a JSON?

I'm trying to traverse attributes of a json, I'm trying that way for (var i = 0, length = r.length; i < length; i++) { for (var i2 = 0,length = r[i].lenght; i2 < length; i2++ ){ console.log("teste"+r[i][i2]); } } How...
asked by 27.10.2015 / 13:06
1
answer

What is the correct MIME type?

In order to allow data to be exchanged between the server and the browser, a number of means are usually adopted, for example when returning an existing dataset in the database using JSON . There are these here: application / json appl...
asked by 17.10.2015 / 02:12
1
answer

How to create modular function whose parameter is an operator?

I assume that I want to create a function that changes the src of an image by another in the index of an array, like this: var arrayimgs = ["js/img1.jpg","js/img2.jpg","js/img3.jpg"]; var imagem = document.getElementById('imagemslide');...
asked by 06.12.2014 / 15:41
2
answers

jQuery.preventDefault (), jQuery.stopPropagation () and jquery.StopImmediatePropagation () ... without jQuery!

There is a crossbrowser implementation for the jQuery.Event.preventDefault () methods, jQuery.Event.stopPropagation () and jQuery.Event.stopImmediatePropagation () does not require jQuery? I have a very specific resource that would no...
asked by 27.11.2014 / 12:40