?
Solved

JQuery CountDown

Posted on 2010-08-26
7
Medium Priority
?
804 Views
Last Modified: 2012-05-10
Hi there,

The following is the datetime field value stored in an SQLserver database in Brazil:  2010-08-26 21:46:42.380

I parsed it inside SQLserver, to be able to get the year, month, hour and minute.

Now I need to fill the "until" countdown parameter in the Jquery CountDown Javascript package... the link to it is below.

I did like below:

until: new Date(myYear, myMonth - 1, myHour, myMinute + 40), timezone: -3

because I want to give 40minutes, from the time stored, to the countdown timer.  

The number that appears has NOTHING to do with 40minutes after the time stored. How should I understand/fix that?

Thanks!
Link: http://keith-wood.name/countdownRef.html#labels 
0
Comment
Question by:fskilnik
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
7 Comments
 
LVL 82

Accepted Solution

by:
leakim971 earned 2000 total points
ID: 33538233
Try :

until: new Date(myYear, myMonth - 1, myHour, myMinute + 40, 0), timezone: -3
0
 

Author Comment

by:fskilnik
ID: 33538372
Nope... it appears:  0 hours, 0 min and 0 seconds ...
0
 
LVL 82

Expert Comment

by:leakim971
ID: 33538384
the day is missing too :

until: new Date(myYear, myMonth - 1, myDay, myHour, myMinute + 40, 0), timezone: -3

please confirm myYear, myMonth, MyDay myHour and MyMinute is set somewhere (from the database)
0
7 Extremely Useful Linux Commands for Beginners

Just getting started with Linux? Here's a quick start guide that has 7 commands that we believe will come in handy.

 

Author Comment

by:fskilnik
ID: 33538452
Sorry, but in the code is not missing (my fault when typing here at EE, only)... have a look:

until: new Date(<%=(rsParsingStartTimes.Fields.Item("YearStart").Value)%>, <%=(rsParsingStartTimes.Fields.Item("MonthStart").Value)%>-1 , <%=(rsParsingStartTimes.Fields.Item("DayStart").Value)%>, <%=(rsParsingStartTimes.Fields.Item("HourStart").Value)%>, <%=(rsParsingStartTimes.Fields.Item("MinuteStart").Value)%> +40,0), timezone: -3});
0
 

Author Comment

by:fskilnik
ID: 33538560
Perhaps the problem is NOT related to that, leakim... now I´m checking!
0
 

Author Comment

by:fskilnik
ID: 33538643
That´s it... it WASN´T that at all, it was a problem of reading the recordset...

Well, thanks a LOT, anyway.

See you in my next difficulties, I hope.  

Best Regards, fskilnik.
0
 
LVL 82

Expert Comment

by:leakim971
ID: 33540976
Thanks a lot for the points! No problem for the next steps, have fun!
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

There are a couple ways to attach a JavaScript function to dynamically created elements. You can make a new script for each element as it’s created or you can use delegation. Delegation allows a single script that is added at page creation to mat…
I found this questions asking how to do this in many different forums, so I will describe here how to implement a solution using PHP and AJAX. The logical flow for the problem should be: Write an event handler for the first drop down box to get …
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
Suggested Courses

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question