>
How to get the localtime in php (without client si...
Welcome, Guest

by tiru on Wednesday, 24 June 2009
How to get the localtime in php (without client side Javascript)


It is sometime needed to extract the local timezone of the user. As the user can change the time in the local machine. So we may can't get the correct time from the javascript.

A better solution is to track the IP of the user by using MaxMind.

1) Implement the maxmind in your website http://geolite.maxmind.com/download/geoip/api/php/
2) You will get the lat/lng and country code.
3) Use this link to get the timezone http://geolite.maxmind.com/download/geoip/api/php/timezone/ 
4) Your php version should be more than 5.1. Then use these following commands
     get_time_zone();
     date_default_timezone_set();
5) It will set the time of the user local time. :) 



Blogger Image
My Blog Title

Product Engineering, software engineering company, Product Development, Product Migration, Product Re-engineering, Product Maintenance, Product Testing Commercial Application Development, Business Software development, commercial software for startups, Application Support and Maintenance, software testing Product Maintenance, Outsource product maintenance, product support and maintenance Product Migration, Product Re-engineering, product re-engineering services Product Research, Product Engineering, UI Prototyping Services Software Testing Services, Quality Assurance services, professional software testers, Load Testing, Functional Testing, Cross Platform, Browser Testing, Test Automation, Testing Tools, software quality analysis Functional Testing Services, software quality analysis, Software Testing Services, Application Testing Services, Functional Testing Types Automated Testing, Automated Testing Services, automation testing, test script development, Automation Test Tools, outsource automation testing Load Testing, Performance Testing Services, Load Testing Tools Offshore Software Development, Outsource software services, offshore outsourcing services, offshore software development services, IT outsourcing services, software quality assurance services, Offshore IT services, Custom Application Development Services, Offshore Product Engineering Benefits of IT Outsourcing, Offshore Software Development companies, offshore software development firms Outsource planning, IT outsourcing, IT development services, offshore IT companies, offshore software development Offshore Software Development, Outsource software services, offshore outsourcing services, offshore software development services, IT outsourcing services, software quality assurance services, Offshore IT services, Custom Application Development Services, Offshore Product Engineering Offshore Software Development, Outsource software services, offshore outsourcing services, offshore software development services, IT outsourcing services, software quality assurance services, Offshore IT services, Custom Application Development Services, Offshore Product Engineering