Set function short_open_tag to off

  • Hi all, I hope this is the right place for posting my question.
    I need to set short_open_tag to off.
    Your help is much appreciated.
    Thank you in advance

    O.S.: Debian Jessie
    Apache 2.4
    MySQL 5.5
    Php 5.6
    i-MSCP ver.: latest
    Location: Italy

  • @VeNoM


    Hello,


    You can edit the pool configuration file that belongs to your site manually (e.g /etc/php5/fpm/pool.d/<site>.conf), and add something like this at bottom:


    Code
    1. php_admin_flag[short_open_tag] = off


    and then, once done, reload your FPM instance: service php5-fpm reload


    However, the problem with that method is that this parameter will be gone if you edit the domain or if you update/reconfigure i-MSCP.


    A better approach is to use the following listener file: https://github.com/i-MSCP/imsc…p_confoptions_override.pl


    In order you must:

    • Upload that listener file into the /etc/imscp/listeners.d directory
    • Edit the listener file according your needs (if you need help on that part, feel free to ask)
    • Run the following command to enable it: perl /var/www/imscp/engine/setup/imscp-reconfigure -danv

    By doing this, your changes will be persistent ;)

    badge.php?id=1239063037&bid=2518&key=1747635596&format=png&z=547451206

  • Thank you for your help Nuxwin,
    and excuse me if I take advantage of your kindness.


    Domain name apart, the only two questions are:
    1) what I have to set in code below
    2) what I've have to do for set two or more domains



    O.S.: Debian Jessie
    Apache 2.4
    MySQL 5.5
    Php 5.6
    i-MSCP ver.: latest
    Location: Italy

  • Domain name apart, the only two questions are:
    1) what I have to set in code below
    2) what I've have to do for set two or more domains


    Well, If you want add your configuration parameter for all domains, you can do:

    Perl
    1. # Any PHP configuration option added here will apply globally (to all domains). '*' => { 'short_open_tag' => 'off', },

    and comment the per domain configuration section.


    Now if you want add that parameter to specific domains only, you can do:

    Perl
    1. # Any PHP configuration added here will apply to domain1.tld only
    2. 'domain1.tld' => {
    3. 'short_open_tag' => 'off'
    4. },
    5. # Any PHP configuration added here will apply to domain2.tld only
    6. 'domain2.tld' => {
    7. 'short_open_tag' => 'off'
    8. }

    and comment the global section.


    Got it ?

    badge.php?id=1239063037&bid=2518&key=1747635596&format=png&z=547451206

  • Many many thanks Nuxwin,
    I try to set later because now I've to transfer a lot of domains from one server to another.
    I'll report soon any issue if any but considering your detailed description there should not be any problem.



    Thank you again for your great support and have a nice day

    O.S.: Debian Jessie
    Apache 2.4
    MySQL 5.5
    Php 5.6
    i-MSCP ver.: latest
    Location: Italy

  • @VeNoM


    You're welcome.

    badge.php?id=1239063037&bid=2518&key=1747635596&format=png&z=547451206

  • Good night Nuxwin and sorry for my big delay.
    Thank to your support now my servers work well.
    I've incontered (apparently) a new little problem but i will open a new thread for this.
    Have a nice day and thank you again

    O.S.: Debian Jessie
    Apache 2.4
    MySQL 5.5
    Php 5.6
    i-MSCP ver.: latest
    Location: Italy