Enable Short Tag in PHP
To enable short_open_tag edit PHP configuration file “php.ini” and set following value to On. Default this value is set to Off.
short_open_tag = On
After making above changes restart Apache service.
Verify Short Tag in Enabled
To verify that short tag is enabled in your PHP configuration. Create a file check.php with following content.
[php]
Now execute this script using the command line or access file in a web browser.
php check.php
Result if PHP Short Tag is
PHP short open tag test
Result if PHP short tag is
<? echo "PHP short open tag test"; ?>
2 Comments
important! string number in config file is near 212
thank you