Подтвержденный Замкнутый цикл Подписывается, единственный способ обработать подписки. Это должно быть честным требованием Вашим клиентам. Если Вы получаете жалобу, требуете доказательство подтверждения. Если они не могут обеспечить его, то у Вас есть ситуация для контакта с. В этом случае, если это не был изолированный инцидент, Вы, вероятно, уже помещены в черный список.
I have a fairly default CentOS 6.3 system with PHP 5.3.3 to hand and it works as expected. Changing the value of short_open_tags in /etc/php.ini and restarting the httpd service just works.
PHP also reads the files in /etc/php.d
so check that it's not being overridden in one of them.
If you want to check for other php.ini files then
find / -name php.ini
A bit more information, the value of short_open_tag can be set in a .htaccess file too
php_value short_open_tag On
Most likely, you have eAccelerator or something similar enabled. Pre-compiled pages are not processed, so just clear eAccelerator cache, or (ugly) uninstall eAccelerator, restart Apache, re-install eAccelerator, restart Apache..
Также убедитесь, что файл
.htaccess
на пути к вашему скрипту содержит директиву short_open_tag
, которая может быть конфликтующей ( в моем случае этот файл в каталоге верхнего уровня был источником проблемы) Я вижу, что все ответы выше только частично верны. На самом деле все PHP-приложения 21-го века будут иметь FastCGI Process Manager(php-fpm), так что как только вы добавили php-info() в ваш скрипт test.php и проверили правильный путь для php.ini
Go to php.ini and set short_open_tag = On
IMPORTANT: тогда вы должны перезапустить ваш php-fpm процесс, чтобы это могло сработать!
sudo service php-fpm restart
и затем перезапустите ваш nginx/http сервер
sudo service nginx restart
на centos6 /etc/php.ini должно быть место, убедитесь, что оно не определено несколько раз в файле.
По умолчанию, есть описание тега в разделе "Quick Reference":
; short_open_tag
; Default Value: On
; Development Value: Off
; Production Value: Off
не добавляйте туда тег, так как он установлен позже в разделе "Language Options" (который перезапишет вашу настройку):
; This directive determines whether or not PHP will recognize code between
; <? and ?> tags as PHP source which should be processed as such. It's been
; recommended for several years that you not use the short tag "short cut" and
; instead to use the full <?php and ?> tag combination. With the wide spread use
; of XML and use of these tags by other languages, the server can become easily
; confused and end up parsing the wrong code in the wrong context. But because
; this short cut has been a feature for such a long time, it's currently still
; supported for backwards compatibility, but we recommend you don't use them.
; Default Value: On
; Development Value: Off
; Production Value: Off
; http://www.php.net/manual/en/ini.core.php#ini.short-open-tag
short_open_tag = Off