Server-side Time Refresh Solution

Source: Internet
Author: User
Server-side Time Refresh
The younger brother is doing the hand swims wants to consult under
Front-end Request my server-side time
I should have passed it to him. Current time on server side
So I should always refresh myself so how to refresh in real time
What's the plan?
Need to use as little resources as possible Mobile Games Server Front End

Share to:


------Solution--------------------
Your "visualization" also is a solution, but not you refresh time (time is objective) but you show it in your way
This is not usually the case, but it is the time to start sending the server to the user to calculate the time difference between the user and the server. This kind of JS Countdown code a lot, you can go to find

------Solution--------------------
The big version is right.

And you can actually "get the prize" and then judge whether it's within the time frame.

Time () on the server should always be the current server, right? @xuzuning
------Solution--------------------
Citation:
version Big said yes

And you can actually "get the prize" and then judge whether it's within the time frame.

Time () on the server should always be the current server, right? @xuzuning


Time () Gets the times of the server. Can do this: the beginning of the server time to pass through, and then in the verification of the time to the server, the client side how Paddy does not matter, after all, determine the success of the key factors in the hands of the server.
  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.