Questions tagged as 'javascript'

1
answer

Event delegation only once, in a 'dynamic' scenario

I have a function hello() whose argument is the return of an ajax call: function hello(msg) { alert(msg); } $.ajax({ url: 'example.com', data: data }).done(function(resp) { // abre_modal // apenas no fecho (clic...
asked by 17.08.2017 / 17:16
1
answer

I can not sort table rows

I created a whole stylization for the table I did everything in the first row of the table was ok, but when I was duplicating this line I noticed that only the first one was the stylization, I'm starting in the area, / p> <html lang="en">...
asked by 05.11.2017 / 01:11
2
answers

Catch text from an input text

I have the following form <form method="POST"> <input id="comentario" type="text" name="comentario" id="comentario"> <input type="submit" name="Comentar" value="Comentar" id="Comentar"> </form> It is necessary to d...
asked by 08.11.2017 / 22:54
1
answer

jQuery does not recognize .click event of a class added with append [duplicate]

Folks, I can not get the .click event of a button that is added with the append command to work. Here is the function that contains append: function mostrarUploads(nome, tabela) { var $table = $(tabela); $table.html("");...
asked by 08.11.2017 / 13:54
1
answer

How to control the event to leave the page?

I put an event using JavaScript in a <a> tag that is styled as a button, the event is only to show a message that the user will exit the page. But the message looks like all <a> tags, and I want it to ask only when the user c...
asked by 08.11.2017 / 04:35
1
answer

Ng-repeat by passing a number

I want to set a select whose options will be generated by a ng-repeat, but for this I want to pass a number, for example if I pass the number 5 in the variable will be set 5 options with values 1,2,3,4 , 5. <md-select ng-disabled="!novoCada...
asked by 07.11.2017 / 03:01
1
answer

Multiple Upload Thumbnail

I have a field for uploading PDF documents, when appending a document the PDF icon appears, however I am using multiple upload and only one icon appears when it would be ideal for an icon to appear for each file attached, I know it is possible b...
asked by 24.08.2017 / 13:16
3
answers

Transfer the value of a variable to Ctrl + C

Does anyone know if there is a way to transfer the value of a variable to Ctrl + C? I'm working with AngularJS and within the scope I have a variable that I would like to pass to the clipboard, but I can not find anything that will help me....
asked by 15.09.2017 / 20:51
1
answer

jQuery - hide () and show () does not run correctly

I have items that in a paragraph is displayed the total of the same. When I remove one of these items, I'm working with 2 paragraphs with the same code so I hide one and show the other so I can display the correct value. However, when I click th...
asked by 15.09.2017 / 20:30
1
answer

Does anyone know a simpler way to do this, by showing the text instantly when typing in an input

<html> <head> <script class="jsbin" src="http://ajax.googleapis.com/ajax/libs/jquery/1/jquery.min.js"></script><title>Teste</title></head><body><divid="formVal"> <form name="fvalida">...
asked by 13.09.2017 / 14:25