• <legend id='Hcizx'><style id='Hcizx'><dir id='Hcizx'><q id='Hcizx'></q></dir></style></legend>
  • <small id='Hcizx'></small><noframes id='Hcizx'>

      <tfoot id='Hcizx'></tfoot>
      • <bdo id='Hcizx'></bdo><ul id='Hcizx'></ul>

      1. <i id='Hcizx'><tr id='Hcizx'><dt id='Hcizx'><q id='Hcizx'><span id='Hcizx'><b id='Hcizx'><form id='Hcizx'><ins id='Hcizx'></ins><ul id='Hcizx'></ul><sub id='Hcizx'></sub></form><legend id='Hcizx'></legend><bdo id='Hcizx'><pre id='Hcizx'><center id='Hcizx'></center></pre></bdo></b><th id='Hcizx'></th></span></q></dt></tr></i><div id='Hcizx'><tfoot id='Hcizx'></tfoot><dl id='Hcizx'><fieldset id='Hcizx'></fieldset></dl></div>

        如何获得客户的准确当地时间?

        时间:2023-09-06

        <i id='iYe42'><tr id='iYe42'><dt id='iYe42'><q id='iYe42'><span id='iYe42'><b id='iYe42'><form id='iYe42'><ins id='iYe42'></ins><ul id='iYe42'></ul><sub id='iYe42'></sub></form><legend id='iYe42'></legend><bdo id='iYe42'><pre id='iYe42'><center id='iYe42'></center></pre></bdo></b><th id='iYe42'></th></span></q></dt></tr></i><div id='iYe42'><tfoot id='iYe42'></tfoot><dl id='iYe42'><fieldset id='iYe42'></fieldset></dl></div>
        <legend id='iYe42'><style id='iYe42'><dir id='iYe42'><q id='iYe42'></q></dir></style></legend>
        <tfoot id='iYe42'></tfoot>

        <small id='iYe42'></small><noframes id='iYe42'>

            <tbody id='iYe42'></tbody>
                <bdo id='iYe42'></bdo><ul id='iYe42'></ul>

                • 本文介绍了如何获得客户的准确当地时间?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

                  问题描述

                  无论客户端系统的时区如何,获取客户端本地时间的最佳方法是什么?我正在创建一个应用程序,我首先需要获取客户访问地点的确切时间和日期.即使检测客户端系统的 IP 地址也有缺点,或者检测客户端系统的时区有时可能会有风险.那么,有什么方法可以真正可靠且不易出错,因为向客户显示错误的时间和日期是一件非常尴尬的事情.

                  What is the best method to get the clients local time irrespective of the time zone of clients system? I am creating an application and i need to first of all get the exact time and date of the place from where the client is accessing. Even detecting the ip address of client system has a drawback or detecting the time zone of client system may be risky at times. So, is there any way out which could be really reliable and not vulnerable to error because displaying wrong time and date to client is something very embarassing.

                  推荐答案

                  在 JavaScript 中?只需实例化一个新的日期对象

                  In JavaScript? Just instantiate a new Date object

                  var now = new Date();
                  

                  这将使用客户端的本地时间创建一个新的 Date 对象.

                  That will create a new Date object with the client's local time.

                  这篇关于如何获得客户的准确当地时间?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持html5模板网!

                  上一篇:toRad() Javascript 函数抛出错误 下一篇:(英国)裁剪地图上 x 和 y 的墨卡托经度和纬度计算

                  相关文章

                  最新文章

                    <i id='AFB9b'><tr id='AFB9b'><dt id='AFB9b'><q id='AFB9b'><span id='AFB9b'><b id='AFB9b'><form id='AFB9b'><ins id='AFB9b'></ins><ul id='AFB9b'></ul><sub id='AFB9b'></sub></form><legend id='AFB9b'></legend><bdo id='AFB9b'><pre id='AFB9b'><center id='AFB9b'></center></pre></bdo></b><th id='AFB9b'></th></span></q></dt></tr></i><div id='AFB9b'><tfoot id='AFB9b'></tfoot><dl id='AFB9b'><fieldset id='AFB9b'></fieldset></dl></div>

                    <legend id='AFB9b'><style id='AFB9b'><dir id='AFB9b'><q id='AFB9b'></q></dir></style></legend>

                      • <bdo id='AFB9b'></bdo><ul id='AFB9b'></ul>

                    1. <tfoot id='AFB9b'></tfoot>
                    2. <small id='AFB9b'></small><noframes id='AFB9b'>