Questions tagged as 'javascript'

2
answers

Avoid changing tab with javascript

I am working with tabs on my project, the tab I build it like this: <div class="tab-container"> <ul class="nav nav-tabs nav-fill" role="tablist"> <li class="nav-item"> <a class="nav-link active" dat...
asked by 03.07.2018 / 17:18
2
answers

Send form with onClick. Only Javascript and HTML

I'm doing the shopping cart part of a page (It's a college job, I'm just starting). For each item in the cart you should be able to increase and decrease the quantity purchased. I managed to do it but only with one product, if I copy and paste s...
asked by 21.06.2018 / 22:55
2
answers

Can not read property 'length' of undefined JAVASCRIPT

I'm just a fan of programming and as such I'm running into a certain problem. The code below gives me the following error: Cannot read property 'length' of undefined at computeCourses If I run the computeCourses () function from the chr...
asked by 18.06.2018 / 22:42
2
answers

Remove property from JavaScript object

As an example, we can pose an object in the following way: var myObject = { "Event": "Prueba", "method": "post", "url": "http://" }; What is the best way to remove the url property to end with a new myObject object...
asked by 27.08.2018 / 18:12
3
answers

'For in' does not recognize the elements in an array

I have the following problem with a 'for in' loop: it does not want to recognize the elements of the array. I tried to see the elements after calling the 'for in' with the console.log, but it returns 0. function isValidWalk(walk) {...
asked by 02.07.2018 / 18:48
1
answer

Cut text from an input stored in a variable with javascript or jquery

I am storing in a variable the .text of a input . For example the text variable: texto = "Esto-es un mensaje" I want to save part of the content of that text in another variable. So where is the script that saves for ex...
asked by 01.09.2018 / 19:02
2
answers

"Can not POST" in node.js and postman

It happens that I have this code, where I try to pass by the user parameter and password using as a postman tool, I'm honestly new to this so I do not know if I'm doing well or the code is wrong since I get this error in postman app.post...
asked by 05.09.2018 / 17:23
2
answers

Take the value of an HTML id with Jquery

Something I have to be doing wrong but I do not see what. I have a list of divs and I want them to click on an item in the list to take their id. I currently have this but I can not get it to work. (function($) { function selectPara...
asked by 21.02.2018 / 15:15
2
answers

Add values obtained in javascript

Good morning. How can I make the sum of values obtained from JSON and interpreted with JS. In the following code I get my data brought with json and I go through it with the for to show them, among them the campo datos[dato].bultos I n...
asked by 01.03.2018 / 15:56
2
answers

Delete all the following text to a character X

I have a query. I need to remove all the text that follows a sign that I determine , in this case the bar . I get the string of characters from a text field and store it in a variable. Example: www.mipagina.com/publicaciones/favorit...
asked by 18.02.2018 / 21:03