Questions tagged as 'javascript'

1
answer

how to load read JSON file in JS and load search result in HTML code?

I made this javascript code in a .js file, where my intent is to get the data from a JSON file and use it in my HTML. I do not know how to use the $ .getJSON function in my code to do this and put one thing together. Thanks for any help. funct...
asked by 13.06.2017 / 20:33
1
answer

Which framework do you recommend for unit testing in javascript (ECMAScript 6)?

I will develop a web application using ECMAScript 6. I would like to continue with the TDD Technique. What framework do you recommend for unit testing in javascript (ECMAScript 6)?     
asked by 16.06.2017 / 21:23
3
answers

Adding inputs with jquery and real-time

I need a jquery script to do the following: TOTAL = Fine + Interest - Discount. that computes even if one of the 3 inputs is not filled. I found some examples on the internet, but everyone needs an action, a function or a button to pres...
asked by 09.06.2017 / 20:14
1
answer

Failed to load script with angle (ng-view)

I'm doing a design with angular js and using the design lite (mdl) material for the layout. Some features of mdl require a javascript file to work, but this file has some loading, sometimes not. I believe the browser ends up loading the mdl java...
asked by 16.06.2017 / 18:33
3
answers

Add values of two inputs and show in third

I'm a beginner in jQuery and I'm not able to add the values of two different inputs and show a third input the result without refreshing the screen. Could someone help me? These are the form fields: <div class="form-group" id="formvalor"...
asked by 12.06.2017 / 22:54
2
answers

How to make a DIV disappear after a few seconds

In my adventure to discover html / php, I came across another problem. I have a DIV, where the user data appears after a correct login, and would like to make that DIV disappear through javascript. This is my index.php: <?php include('se...
asked by 12.06.2017 / 13:31
1
answer

Angular: Module name is not loaded in html ngApp tag

I'm doing a basic angled test that reads a simple json and displays on the screen. My problem is that when I put in the module name the module name in the ng-app tag all angular functions stop working. Inspecting the chrome code I found th...
asked by 29.06.2017 / 22:01
1
answer

Javascript passes more than one parameter

I have this code: 1 == a.redirect ? window.location = rootUrl + "/options/?welcome=true" : ($("#message").css("display", "block"), $("#message").html(a.message)), $("#signinButton").attr("value", "Entrar") I would like to pass three more pa...
asked by 01.07.2017 / 10:14
2
answers

Hide a div and show another when clicking a button using javascript only

I'm trying to do a quiz and I want one question to appear at a time. I used the css property display: none; to hide, and created a function in javascript that receives as a parameter the id of the div that has to be shown. Clicking% w /%...
asked by 13.07.2017 / 19:11
1
answer

callback in removeClass function jQuery

I'm trying to use callback in the removeClass function but it's not working, does anyone know what's wrong? I need to run removeAttr only after removeClass is finished. $(".context_menu_pai").removeClass('ope...
asked by 14.07.2017 / 00:02