Questions tagged as 'javascript'

3
answers

Convert date with timezone

new Date () in javascript returns me this format:    Tue Apr 01 2014 13:43:13 GMT-0300 (BRT) I need to convert this to a java.util.Date. For this I am trying to use SimpleDateFormat () but I did not find a pattern that worked, it always r...
asked by 01.04.2014 / 18:51
3
answers

Function to increment value within div

I'm trying to do a function to increment (every 20ms) +1 in <div> , according to the value that will be inside it: For example: <li class="marcacao" onMouseOver="aumenta('html')">HTML5 e CSS3 <div id="html" class="nive...
asked by 15.02.2014 / 23:58
2
answers

How to sort a JSON in descending order?

I have a JSON value that I want to sort it in descending order (I think in the example you will understand). Example: var json = { 'um': { 'cont': '5' }, 'dois': { 'cont': '10' } ... }; So in this case...
asked by 10.03.2014 / 17:50
1
answer

How to implement a graph using amCharts?

I'm trying to implement a bar / column chart using the own tool from amCharts that uses XML but not I'm able to edit it to stick with a specific bar. What would be the simplest solution for implementation using amCharts?     
asked by 10.02.2014 / 13:46
2
answers

jQuery switch div background specifies

I need a help with the following problem, I have the following HTML, which is part of an accordion <div id="accordion2"> <h3 class="btn-sub-main"><a>Banho</a><div class="seta-btn-sub"></div></h3>...
asked by 17.02.2014 / 19:58
2
answers

How to check database update from a browser?

I'm trying to make a page that updates the <div> (which has the content brought in from the database) automatically as soon as some value is entered (just like that site). I used setInterval to update (with Ajax) the <d...
asked by 12.02.2014 / 18:47
1
answer

2 regular expressions in 1

I found the following regular expression to validate email address in javascript: /^(([^<>()[\]\.,;:\s@\"]+(\.[^<>()[\]\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}...
asked by 22.07.2014 / 15:00
1
answer

.each () in pure Javascript

In a forum platform there is a paging system, and I would like to do this pagination via Ajax, for this, I built the following function: //<![CDATA[ var Pagination = (function(w, d) { var pagination = { init: function() {...
asked by 26.07.2014 / 22:16
4
answers

Automated tool to join multiple stylesheets (CSS) in 1 only and to join Scripts (JS) in 1 Sheet only

I searched the internet for ways to join Stylesheets CSS and Script Sheets JS in an automated way, but did not work well. I have about 17 Style Sheets and 15 Scripts, if I do it manually I will be "crazy" and it will take a...
asked by 24.07.2014 / 03:13
2
answers

Button that when clicked shows only the content of a certain class

Hello, I'm creating a Javascript system, where I need a button to show only the paragraphs with a given class in a div with hidden content. Example: <button id="btn1">Abre classe1</button> <div id="conteudo"> <p...
asked by 24.07.2014 / 23:14