Elxis CMS Forum

Support => General => Topic started by: ROUBOS on April 13, 2011, 11:39:44

Title: Cannot access php.ini for timezone correction.
Post by: ROUBOS on April 13, 2011, 11:39:44
Hi,
Getting this error " ELXIS WARNING: There is no Timezone indentifier defined! " During installation. Is there a way to fix this with the .htaccess file or something? I have no access to the php.ini file

thanks a lot
Title: Re: Cannot access php.ini for timezone correction.
Post by: ROUBOS on April 13, 2011, 11:40:46
Yes sorry, I think I got it.
Add the following to the .htaccess file right?

php_value date.timezone "Europe/Athens"

oops: now getting Internal Server Error!
Title: Re: Cannot access php.ini for timezone correction.
Post by: Ivan Trebješanin on April 13, 2011, 11:58:27
It has to be set in php.ini, so you can ask your hosting to set it.
Title: Re: Cannot access php.ini for timezone correction.
Post by: ks-net on April 13, 2011, 19:28:25
probably your server runs on cgi/fastcgi....if so then you have to contact your provider

but you can work a little around to see what your environment is

find what your php environment is  in administartor>>system>>site-info>>php
look for "Web Server to PHP interface:"  value
or in phpinfo() page look for "server api" value .

if your php runs as mod_apache(apache handler) or suphp  or cgi you can try one of the solutions here:
http://wiki.elxis.org/wiki/PHP_settings


Title: Re: Cannot access php.ini for timezone correction.
Post by: ROUBOS on April 13, 2011, 22:48:41
Can I go ahead with the install and sort out the time zone later?
Title: Re: Cannot access php.ini for timezone correction.
Post by: ROUBOS on April 27, 2011, 12:31:47
They told me that the timezone is set to Athens, but I do get the warning message in the installation.
Should I go ahead with the install?  ???
Title: Re: Cannot access php.ini for timezone correction.
Post by: ks-net on April 27, 2011, 12:49:01
did they restart apache after the new settings applied?
Title: Re: Cannot access php.ini for timezone correction.
Post by: ROUBOS on April 27, 2011, 12:59:25
not sure, you see it's a government hosting space
from what they say it has always been set.
Should I re-ftp elxis?
Title: Re: Cannot access php.ini for timezone correction.
Post by: ks-net on April 27, 2011, 14:04:35
did you take a phpinfo?
Title: Re: Cannot access php.ini for timezone correction.
Post by: ROUBOS on April 27, 2011, 14:11:23
looked at php info and yes it shows that its set to Athens. I sent a request on the helpdesk to restart the Apache server.
Title: Re: Cannot access php.ini for timezone correction.
Post by: ks-net on April 27, 2011, 14:17:59
since it is there the value... no need for restart apache...

you said that elxis still complain about timezone ?

Note: we want this  => date.timezone = " "   not to be empty

what is your " Server API " as ti is shown in the phpinfo?
maybe you can set this value .. did you read this:
http://wiki.elxis.org/wiki/PHP_settings


yes is mandatory  date.timezone not to be empty as it is mentioned here:
http://wiki.elxis.org/wiki/Set_timezone
Title: Re: Cannot access php.ini for timezone correction.
Post by: ROUBOS on April 28, 2011, 11:34:41
OK, I have no access to the php.ini file. in php info it has "Default timezone    Europe/Athens"
I was informed that it has always been set to Athens so there is no need for Apache restart
In the php info I also get this: "date.timezone   no value   no value "
Title: Re: Cannot access php.ini for timezone correction.
Post by: ks-net on April 28, 2011, 11:38:13
so there is no value....

what is your  server's Api?
Title: Re: Cannot access php.ini for timezone correction.
Post by: ROUBOS on April 28, 2011, 11:48:59
Is this it?:
Server API    CGI/FastCGI
Title: Re: Cannot access php.ini for timezone correction.
Post by: ks-net on April 28, 2011, 12:05:13
with fastcgi you have only one option...
contact hosting provider and tell to add the directive in php.ini
or setup a custom ini for you

add =>  date.timezone = "Europe/Athens" 
Title: Re: Cannot access php.ini for timezone correction.
Post by: ROUBOS on April 28, 2011, 12:13:00
thank you,
just made another request to the them. see how we go this time :(
I did try .htaccess before with no luck
Title: Re: Cannot access php.ini for timezone correction.
Post by: ROUBOS on April 28, 2011, 12:52:34
OK done, they fixed it :)
The following are my only issues but I guess I can live with them :)

Εμφάνιση Σφαλμάτων:       Ενεργό
Magic Quotes GPC:                Ενεργό
Allow URL fopen:                   Ενεργό
Short Open tag:                       Ενεργό
Title: Re: Cannot access php.ini for timezone correction.
Post by: ks-net on April 28, 2011, 13:55:06
yes you can live with them....are not mandatory they are only recommendations

***

most probably they set for you a new php.ini
if this php.ini is in a path writable by you  then you can modify it...

you can see if this happen by looking  the values of:

"Loaded Configuration File"
"Scan this dir for additional .ini files "

if so modify it and wait or ask for apache restart


****for people having the way to choose*******

cgi secure but very slow

fastcgi
is the most tide and secure and fast enough ... seems that more and more server-setups nowdays go with fastcgi

suphp  is the most flexible and  also secure but  slower from fastcgi

mod_apache
is the fastest but most insecure of everything

if you are a server admin probably you want fastcgi
if you are site-owner you will love suphp

Title: Re: Cannot access php.ini for timezone correction.
Post by: ROUBOS on April 28, 2011, 22:54:57
Thanks for all your help :)