Questions tagged as 'javascript'

1
answer

capture value input text javascript

So I'm studying oop in javascript to crawling yet, for this I'm trying to add elements to my site dynamically through js I want to capture the value of my text field and when I click on the add button the element will be created...
asked by 24.12.2016 / 22:24
2
answers

Formatting date and time with Javascript? [duplicate]

I'm consuming data from a API and would like to know how to pass the following date and time value to the Brazilian standard. The format returned is this: 2017-01-05T14:35:17.437 but I'd like it to be displayed 05-01-2017    ...
asked by 05.01.2017 / 20:12
2
answers

Adding date tags to the button with jquery

I need to add tags data to my button when I hover over it, I already get the mouse hover move now I need to add the tags , which are: data-trigger="hover" data-toggle="popover" data-placement="bottom" data-content...
asked by 11.01.2017 / 00:18
3
answers

JSON.parse error: Unexpected end of JSON input

I'm trying to get the response from a xhr request: ... xhr.send(formData); var resposta = JSON.parse(xhr.responseText); console.log(resposta); ... Console displays this error: Uncaught SyntaxError: Unexpected end of JSON input But I c...
asked by 12.01.2017 / 17:44
1
answer

How to change Google Maps theme?

I am developing a project, a site and in it I have a dark map of Google Maps, it is a common map with a specific coordinate of Latitude and Longitude, but I would like this map to be dynamic and with another theme, for example: theme blue, with...
asked by 18.06.2016 / 23:30
1
answer

Wide Angle API

I am trying to make a request using angular connecting to REST API built in laravel. XMLHttpRequest cannot load http://localhost:8000/rest/v1/entidades/licitacoes. No 'Access-Control-Allow-Origin' header is present on the requested resource....
asked by 21.06.2016 / 20:31
3
answers

Field within a variable dynamically?

Follow the code below: JavaScript: var img1 = false; var img2 = true; var img = "img"+1; //Resultado da variavel img é "img1". //Como converter string para variável ? //Exemplo: "img1...
asked by 25.11.2016 / 20:34
1
answer

Catch the attribute of an element

How do I select the color of the div element's backGround? Note: Using javascript var cor; cor = document.getElementById(id).style.backgroundColor; #bloco1 { width: 280px; height: 120px; border: 1px dashed black; p...
asked by 24.11.2016 / 14:39
1
answer

Redirection with Timer MVC

I have a problem that I'm breaking my head to solve. I'm building an MVC site and would like to make an opening page with Timer rolling like this image: Solong,beauty.TheproblemisthatIwantitwhenIfinishthiscounteritredirectstothehomepage.H...
asked by 08.08.2016 / 22:00
1
answer

Error removing accents

I'm having a javascript code to remove accents, it works with any accent, except with the crass, and by code it should work with kernel as well. I can not find the bug. var teste = "Çaptúra de Tela 2016-04-27 às 18.21.24.png à à"; function...
asked by 20.08.2016 / 21:33