Jump to content

Fincikas

Members
  • Posts

    23
  • Joined

  • Last visited

    Never

Everything posted by Fincikas

  1. Fincikas

    Time

    Im pretty good at PHP, but JavaScript code I got from internet (just copy pasted) and I dont know anything about that , but still thanks for the code and for Unix timestamp name, cause I can start googleing something useful, but if you would mind to save my time and explain where to put, or just to say should I anything put in .
  2. Fincikas

    Time

    Ok, thank you. But I dont understand this: How to get date difference? Difference with what? User and server time? How to subtract and from what? From difference? from time? Sorry for my nobeish, sorry for my flame, sorry I dont red rules and ect. but I stuck with this for weeks, Im trying to solve it and cant. And when i joined PHP/Javascript masters forum and they couldnt explain for total noob a thing Im anoyed, so please explain it in detail, no need to write code, but more detailed. THANK YOU
  3. Fincikas

    Time

    No. That's not what these forums are for. I'm certain once a mod moves this to the proper home somebody will help you with that though. SO what are these forums for? Just type some not understandable sentences that PHP master can understand, and u left us beginners alone. You call that help? Ok if you can give me a code, please explain some steps that u wrote before...
  4. Fincikas

    Time

    Im creating coutdown timer, so if user changes his time on PC it changes in timer too. Could you write any code to help me out, because im using default time zone ant ect. Even if its in the server(hosting) it still changes, but Im mainly working on wamp server now. It is Javascript now, but if I could set undisturbiable default server time, I know how to solve it. Code: <html> <head> <script type="text/javascript"> function cdtd() { var xmas = new Date("December 25, 2012 00:01:00"); var now = new Date(); var timeDiff = xmas.getTime() - now.getTime(); if (timeDiff <= 0) { clearTimeout(timer); document.write("Christmas is here!"); // Run any code needed for countdown completion here } var seconds = Math.floor(timeDiff / 1000); var minutes = Math.floor(seconds / 60); var hours = Math.floor(minutes / 60); var days = Math.floor(hours / 24); hours %= 24; minutes %= 60; seconds %= 60; document.getElementById("daysBox").innerHTML = days; document.getElementById("hoursBox").innerHTML = hours; document.getElementById("minsBox").innerHTML = minutes; document.getElementById("secsBox").innerHTML = seconds; var timer = setTimeout('cdtd()',1000); } </script> </head> <body> Days Remaining: <div id="daysBox"></div> Hours Remaining: <div id="hoursBox"></div> Minutes Remaining: <div id="minsBox"></div> Seconds Remaining: <div id="secsBox"></div> <script type="text/javascript">cdtd();</script> </body> </html> BTW thanks for help
  5. Fincikas

    Time

    Hi, I would like to ask how to set server/website time independent of user PC time, so if person would change his computer time, time in website would stay the same, or back to the normal after reloading the page.
  6. This is almost what my idea was. Can anyone tell me how to do it? How to store simestamp in the table?
  7. Yes thats exeactly what I want, but i dont now anything about cron job. Are here any tutorials or reviews on these forums, maby someone could link me there?
  8. basicly.... Later will be other times to upgrade and ect. but now i wanna know that, wanna know how to upgrate level with time. And i think i get one of sulutions that I cant explain to you...
  9. I just wanna know, is it even posible to do, or maby you know better sulution? because all this day i can find the sulution....
  10. ...... I just got idea how to make what i want: 2. How to do something like this, if someone press the link, in database or somewhere should start to count the time. After that time counts down, something should automaticly inserts into database. Exaple: I press link to upgrade level. Level takes 5mins to upgrade. After 5min my level should become 2 from 1. And that should change that level 1from database and add level to2. So if i press the link i get timestamp numbers, then i will add 5min. and than time target will be (time then the link was presssed +5mins) and then time reach the target, i can start to do something with mysql... I hope now it is clear (then, then, then, then....... Sorry for bad english.)
  11. Are there any tutorials in these forums how to do it?
  12. sorry. I want something like that. Then i press the link i get current timestamp in variable and it wont change it saves what it was then i press the button. So that variable i can you later in other files and etc. So i want from time() (there is just numbers) numbers put in variable and save it that they wont change for lets say 10minutes and later they automaticly deletes and then it deletes i can press the link again. I hope you understood what i mean, because i dont know how to explain everything exactly. Most off all i need only part one, to get into variable, automaticly delete maby i do it on my own MABY
  13. Dont understood what you mean.
  14. How to do that time()'s numbers from increasing just stops after someone press the link and that resould saves into variable.
  15. I red all pages you give me, but i still cant understand how to use this code in my website.... I know php but i never did anything with javascript, maby here is the point? Can you explain me more about all this?
  16. I got new question, how to do that lets say in one hour in mysql numbers should increases 100. Example: i should get 100resources per hour. So 50resources per 30mins, 1.6resources per 1min and etc. And it should do it all automaticly, all the time.
  17. So, I surfed in google and in youtube, and all I get about timestamp was from what data it is counting and some other unuseful info. So maby you can explain this more like step by step? or maby create all code. Because I can understood code, more than idea
  18. Ok thank you,i dont understood exactly, but now i know how to find what i need thank you very much This topic is solved now for me Thank you again
  19. Hi, Im begginer in all php and i have few questions for experts 1. I wanna set one time for all website or server. So if people will change the time on theyr own computers time in website will not change. 2. How to do something like this, if someone press the link, in database or somewhere should start to count the time. After that time counts down, something should automaticly inserts into database. Exaple: I press link to upgrade level. Level takes 5mins to upgrade. After 5min my level should become 2 from 1. And that should change that level 1from database and add level to2. So all im assking is, tell me much as you can about time and databases Thank you all for answers
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.