minjiera
minjiera

Reputation: 336

I can't find php.ini, how else can I change short_open_tag to off?

I can't find the php.ini but I need to turn short_open_tag to off. How else can I do it?

This is where the file is located But I have no clue how to access it.
loaded Configuration File /usr/local/etc/php5/cgi/php.ini

What I really want to do is to change short_open_tag to off. I tried to upload a new php.ini but it doesn't do anything.

Upvotes: 0

Views: 255

Answers (2)

Flo draven
Flo draven

Reputation: 85

On the console:

vim /usr/local/etc/php5/cgi/php.ini

Alternatively, open up putty and log the entire output, then run:

cat /usr/local/etc/php5/cgi/php.ini

copy the putput to a new textfile, make the changes, copy the content and run:

echo "" > /usr/local/etc/php5/cgi/php.ini --> make the php.ini empty

then:

vim /usr/local/etc/php5/cgi/php.ini

once vim is up , hit "i" and right click , then once more enter, then :

":q" to save and quit

Upvotes: 0

Nik Drosakis
Nik Drosakis

Reputation: 2348

in .htaccess

<IfModule mod_php5.c>
  php_value short_open_tag 1
</IfModule>

php.net

Upvotes: 1

Related Questions