Questions tagged as 'javascript'

2
answers

How to Continue submitting form after "e.preventDefault ();"

I have a code for an animated search bar, but the animation does not work along with submitting the search. I believe it's the "e.preventDefault ();" that I can not bring the event after the animation: <form action='/search' method='get'>...
asked by 21.10.2018 / 16:21
3
answers

How to tell if Modal is scrolling active?

I have a modal that does scrolling when the contents of the window is larger on the screen ..., I would like to put a different class when the modal scrolling was active, in the example below it changes the class even without scrolling: My m...
asked by 10.08.2018 / 17:08
1
answer

Highcharts 3D Column Chart with Amcharts Appearance

How can I customize highcharts so that I do not have the graph rotation on yes, same as Amcharts? The attempts I made were changing the settings alpha: 15, beta: 15, depth: 50, viewDistance: 25 and amcharts settings: "depth3D": 20, "a...
asked by 10.08.2018 / 16:23
1
answer

Get contents source code in Javascript

Hello, I'm trying to use a javascript to read the source code of another page and write that content inside a div. <script type="text/javascript"> $.get('teste.php', function(data) { document.getElementById('somediv').innerHTM...
asked by 09.08.2018 / 23:43
1
answer

Error in logic game in old game in JavaScript?

I'm learning JavaScript and want to make a game of the old one to train. The game is not working and I think it might be a logic bug. function verificar(elemento) { var teste = document.getElementById(elemento).innerHTML; if...
asked by 12.12.2018 / 12:45
4
answers

How to browse a list using each JQUERY

The scenario is as follows: I get a JSON array from my webservice and each time I scroll through the information according to the index (event 1, 2, 3, etc.) My job is as follows: $(document).ready(function(){ $.ajax({ type: "G...
asked by 07.12.2018 / 20:14
1
answer

Simplify and unify functions in one

How can I simplify and leave everything in a single function the script below? var plano_0 = new XMLHttpRequest(); plano_0.open('GET', 'buscar_valor.php?id=10', false); plano_0.send(null); plano_0=plano_0.responseText; plano_0...
asked by 04.09.2018 / 03:52
1
answer

Open link in new tab directly in arrayLink

How can I apply the target=_blank attribute directly to the array below? arrayLink[1]="https://url/cart.php?a=add&pid=00"; I can not apply to HTML. Follow function executed via onclick: function buyVps(){ var vpsDe...
asked by 30.08.2018 / 16:15
1
answer

Promises - this.fileLoad.then is not a function

Good afternoon. I'm having this error - this.fileLoad.then is not a function, could someone please explain to me why this is occurring? fileLoad(){ return new Promise((resolve, reject) =>{ let fileReader = new FileReader();...
asked by 05.07.2018 / 17:07
1
answer

innerHTML does not display the object

I'm using innerHTML to fill a page, its structure goes quiet, the problem is in the variables that contain objects, they are written in full instead of showing their values, I tried to add .text () in their name and resulted on a blank page, wha...
asked by 05.07.2018 / 22:19