Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8406359
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T23:05:21+00:00 2026-06-09T23:05:21+00:00

Lets say I have the following DateTime : DateTime.UtcNow , and I want to

  • 0

Lets say I have the following DateTime: DateTime.UtcNow, and I want to display it on the client according to the user’s time zone, and without recurring to JavaScript.

How should I be doing this? I guess there would be somewhere I should get the time zone for the current request from, somehow, based on the user IP or something?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T23:05:23+00:00Added an answer on June 9, 2026 at 11:05 pm

    Using an IP address to physical address conversion service is the only ‘automatic’ and reliable alternative to JavaScript that I’m aware of. Depending on how accurate you want the IP address to physical location conversion to be you may need to turn to a paid service (I’m thinking if the user is near a timezone boundary you might place them incorrectly).

    I’ve also come across free downloadable databases that match IP address ranges to countries. But these do change from time to time and can be out of date. I would provide a link but it was a while ago that I found this. Hopefully it’s helpful just knowing this sort of thing is out there.

    You should consider that maybe your users want to manually set their preferred time zone in cases where they travel but still want to see the same times (a situation I’ve come across at work).

    Just keep in mind that JavaScript is the easiest solution and most reliable solution so if you can get away with using it… go for it

    Update:

    I’ve found a similar question here that pretty much covers it too How to get current user timezone in c#

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Lets say I have a table with the following columns: Qty, INTEGER SaleDate, DATETIME
Lets say we have following models. class User(db.Model): username=db.StringProperty() avatar=db.ReferenceProperty() class User(db.Model): username=db.StringProperty() avatar=db.StringProperty()
Lets say I have the following: foo = ('animal', 'vegetable', 'mineral') I want to
Lets say I have the following one-to-many relationship: Site has many Users User belongs
I have a list: List<DateTime> timeStamp; Lets say that the list contains the following
Lets say I have the following package Hierarchy: A--> B --> C --> D
Lets say I have the following: f (a, b) = if a == 0
Lets say I have the following script k <- as.numeric(readline(Start Index: )) tot <-
Lets say I have the following: $('input[rel]').jOverlay({ overlayId: #overlayID }); How can I dynamically
Lets say I have the following class: public class Provider { ... public sealed

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.