30ml Posted September 12, 2013 Share Posted September 12, 2013 hi guys, I am on module development process and new on module development. I do not know how to retrieve date and time with prestashop's setting timezone with prestashop format ? Link to comment Share on other sites More sharing options...
jgullstr Posted September 12, 2013 Share Posted September 12, 2013 Timezone is set globally for the shop in config.inc.php, so you wont have to worry about that. (If you for any reason need it, you can get it from Configuration::get('PS_TIMEZONE')) The current languages' formats are stored in the current Language object, usually retrieved from$this->context->language->date_format_lite and$this->context->language->date_format_fullCheck out Tools::displayDate if you have a date string, otherwise just use php's date() function along withdesired format. 2 Link to comment Share on other sites More sharing options...
30ml Posted September 16, 2013 Author Share Posted September 16, 2013 thanks for answer it works fine. thanks due Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now