Can I enable PHP short tags without touching any configuration files?
相关问题
- Views base64 encoded blob in HTML with PHP
- Laravel Option Select - Default Issue
- PHP Recursively File Folder Scan Sorted by Modific
- Can php detect if javascript is on or not?
- Using similar_text and strpos together
You should be able to change it in your .htaccess file if it wasn't locked down
See http://php.net/manual/en/configuration.changes.php for more details
If you have access to an .htaccess but not the php.ini, simply add this to .htaccess in root of the php app you are planning on running:
Checkout this previous Questions:
How to enable PHP short tags - Manual Setting
You can use ini_set function for setting programmatically
Revised: I try using ini_set function to configure it but failed. You can check previous questions for better answer.
I think the
short_open_tag
can't be modified with ini_set().Add into your .htaccess file,