WordPress.org

Forums

Localize Time
[resolved] fail? (8 posts)

  1. davecotter
    Member
    Posted 8 months ago #

    my server is on PDT, i set my computer's time zone to EDT (which should be 3 hours difference), but i get this:

    Tuesday 7:00 PM PDT (8/20/2014, 7:30:00 AM EDT)

    12.5 hours difference? umm, is it broken?

    https://wordpress.org/plugins/localize-time/

  2. JB Christy
    Member
    Plugin Author

    Posted 8 months ago #

    Can you send me a link so I can check it out?

  3. davecotter
    Member
    Posted 8 months ago #

  4. JB Christy
    Member
    Plugin Author

    Posted 8 months ago #

    I set my computer's time zone to be US Eastern (New York) and I see the correct times on your site:

    Appointments and calls accepted during these times:
    Tuesday and Thursday evenings,
    from 7pm to 11pm, GMT -8: Pacific Time (adjust for daylight).

    In your local time zone this would be:
    From: Tuesday 7:00 PM PDT (8/19/2014 10:00:00 PM EDT)
    To: Tuesday 11:00 PM PDT (8/20/2014 2:00:00 AM EDT)

    and:
    From: Thursday 7:00 PM PDT (8/21/2014 10:00:00 PM EDT)
    To: Thursday 11:00 PM PDT (8/22/2014 2:00:00 AM EDT)

    Some things to try:

    1. Ensure your computer's time zone is set correctly.
    2. After ensuring your timezone is set correctly, quit out of your browser and restart.
    3. Open your browser's console and see if you see any Javascript errors. If so, post them here and I'll see if I can figure out what's happening.
    4. Try a different browser, or a different machine if you can.

    By the way, this shortcode is intended to work with a specific date and time, as opposed to "Tuesdays" and "Thursdays". When you say "Tuesday 7:00 PM" it interprets that as "next Tuesday", not Tuesdays in general (8/19 is what I see). The effect will be roughly what you want except for the week right before we start / stop daylight savings time, when the quoted time will be off by an hour. That's not what's causing your problem. I just wanted to be sure you understand how it works.

  5. JB Christy
    Member
    Plugin Author

    Posted 8 months ago #

    FYI, the fact that I see the correct time in both browsers on my machine (Chrome and Firefox on a Mac) means that the server-side part of this plugin is working correctly. The problem must therefore be on the client side, i.e. your machine and / or browser. Your customers may well be seeing the correct times even if you aren't. I know that's not much comfort, but it's something to be aware of.

  6. davecotter
    Member
    Posted 8 months ago #

    I set my computer's time zone to be US Eastern (New York) and I see the correct times on your site

    huh. okay

    i quit my browser and re-ran, now it seems correct to me too

    By the way, this shortcode is intended to work with a specific date and time, as opposed to "Tuesdays" and "Thursdays".

    yeah, i figured.

    When you say "Tuesday 7:00 PM" it interprets that as "next Tuesday", not Tuesdays in general (8/19 is what I see).

    yeah, i know

    The effect will be roughly what you want except for the week right before we start / stop daylight savings time, when the quoted time will be off by an hour.

    hah, interesting. yep that makes sense

    it sure would be nice to be able to adjust the user time zone display, since i do not need / want dates, but only days of week, displayed

    thanks for looking into it! :D

  7. JB Christy
    Member
    Plugin Author

    Posted 8 months ago #

    Oh, good, I'm glad it's working for you now!

    I see in your case that you would want a general "Tuesdays" and "Thursdays" as opposed to specific dates, but the time API's that I have to work with (PHP and Javascript) rely on specific dates. Sorry 'bout that.

    Thanks for using the plugin! Hope you find it helpful.

  8. davecotter
    Member
    Posted 8 months ago #

    it's quite helpful even in it's current form, thanks so much!

Reply

You must log in to post.

About this Plugin

  • Localize Time
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic

Tags