Forums Register Login

i want countdown timer in minutes using jsp

+Pie Number of slices to send: Send
Hello i had one urgent requirement i want count down timer so that when it reaches an hour from we acessing the page it must thrown an alert your time is completed.And also we must able to store the time also
+Pie Number of slices to send: Send
Sounds like validating a user on client side.. how about using JavaScript timer function on page load.
+Pie Number of slices to send: Send
yaa i thought in your way.But the problem is when user com,eout of that page say after 30 mins he must able to acess is remaning 30 mins on any day so what to do then
+Pie Number of slices to send: Send
so it could be handle by database where you have to store the minutes(which user already used) and retrieve and set this value into javascirpt time function..

setting value code into javascript..


just come into my mind..
hope it helps..
+Pie Number of slices to send: Send
Hey saif the risk is how to get the value and store .They are three ways where we can close the page,are we can go to homepage,are we can logout.then what is your idea
+Pie Number of slices to send: Send
 

Originally posted by satya nath:
Hey saif the risk is how to get the value and store.



Yeah you are right.. its not possible to get a value from JavaScript into jsp page.. I don't have much experience in Ajax but I though it could help you to handle this type of conditions..


They are three ways where we can close the page,are we can go to homepage,are we can logout.then what is your idea



calling the same storing method on logout and for close window, implement the unload event in body element. whenever the page is unload this method will call by this event.

hope i would be useful...
+Pie Number of slices to send: Send
satya nath,
Please don't ask the same question in multiple threads.
Doing so creates confusion and wastes the time of the poeple trying to help you.

Please continue this discucssion in its original thread:
https://coderanch.com/t/291494/JSP/java/had-one-importaant-requirement
That's my roommate. He's kinda weird, but he always pays his half of the rent. And he gave me this tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com


Reply locked
This thread has been viewed 2946 times.
Similar Threads
what action listener interface is doing in this code ?
Time-based responses in a JFrame?
EJB Timer Services Query
Timer
Need to restart timer with different time
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 29, 2024 02:38:36.