Questions tagged as 'javascript'

1
answer

Show data dynamically

I have this ajax that requests a list of names for me .. this is the code in pure javascript: function listagem() { var lista = { idUsuario: document.querySelector(".campo").value, token: document.querySelector(".campo-token").value }; le...
asked by 09.02.2018 / 21:51
1
answer

How to edit the bootstrap popup margin in css or js?

Good night everyone, I'm implementing a popover on my page, but I'm doing it inside a table that is inside a jumbotron, the problem occurs from the first 3 lines where the popover appears far from where it should appear, my intention is to figur...
asked by 09.02.2018 / 22:57
1
answer

Show a div when closing the [duplicate]

Well, I'm going to use this site as an example: link Every time you move the mouse towards the close the tab button (or just click on it - whoever you like, you can test by opening any site link in a new tab and access it by the keyboard sho...
asked by 11.02.2018 / 01:30
1
answer

How to remove items from an array?

function converterBinario () { numero = document.getElementById("Valor-decimal").value; var vetor = []; var i =numero; var cont=0; while(i>0){ var resto = Math.floor(numero % 2); if (r...
asked by 31.03.2018 / 05:09
1
answer

How to get the data-value data-list

I have data-list for teacher names, whose values are their names. By default, no input % captures the data contained in value . This causes a problem, since my database expects a numeric value. When I change the values of...
asked by 01.04.2018 / 11:04
1
answer

Filter in Dynamic Select / Option

var escolas = ["UFSCAR", "USP"]; //var alunos = []; $(document).ready(function() { escolas.forEach(function(item) { $('select.lista-escola').append('<option>' + item + '</option>'); }); }); <script src="https:/...
asked by 01.04.2018 / 15:28
2
answers

Identify if a link points to an image, and add a class

On one page, there are links pointing to images. <a class="native-class" href="http://localhost/test/wp-content/uploads/2017/10/7-3.jpg"></a> I'm aware that I could add another class using the native-class class b...
asked by 01.04.2018 / 00:03
1
answer

Check List check and exclude only existing items

I have a check-list done in js, where the user types the task and it appears in the list. But I can only mark as "task completed" or "delete task" the existing tasks, that is, when I include a task I can not delete or mark it. Follow codepen:...
asked by 15.02.2018 / 03:49
1
answer

background-color does not work when used in "classList.toggle ()"

I have the following codes: HTML: <div class="barraLateral" id="barraLateral"> <ul class="menuVertical" id="menuVertical"> <li name="liCat" onclick="darkTheme()"><i class="mdi mdi-theme-light-da...
asked by 14.02.2018 / 19:33
1
answer

Return the URL of an image via JSON

I am communicating with Behance API and I have the following script written in Angular 1.5.5: var app = angular.module('PortfolioApp', []); app.controller('PortfolioCtrl', function($scope, portfolioFactory) { portfolioFactory.getBehance(...
asked by 02.02.2018 / 12:08