How to add .htacces AddHandler application/x-httpd-php .m3u


  • A little of my problem would be salvation. I put up the system and the domain under it one aldomaint.

    It aldomainban they are m3u files in which php there are codes since the devices are that these files can be handled only. I don't know where and how could be this to load up,that the server can handle it.
    i don't know imscp-ben how it is necessary to add this to it.

    Or I do not know it without a panel worked but it handles it some other way totally apache part


    vps server:

    php 7.0 fcgi version Ubuntu 16.04. Apache 2.4 / IMSCP 1.5



    <IfModule mime_module>

    AddHandler application/x-httpd-php .m3u

    </IfModule>



    .htacces file:


    AddHandler application/x-httpd-php .m3u

    AddType application/x-httpd-php70 .m3u


    Not help...

    Edited once, last by Tudatlan ().

  • My subdomain config:


    /etc/apache2/sites-available/sub.domain.conf


    <VirtualHost ip:80>


    ServerName sub.domain.hu

    ServerAlias http://www.sub.domain.hu

    DocumentRoot /var/www/virtual/domain/sub/htdocs

    DirectoryIndex disabled

    LogLevel error

    ErrorLog /var/log/apache2/sub.domain/error.log

    Alias /errors/ /var/www/virtual/domain/errors/

    SuexecUserGroup vu2003 vu2003

    <Directory /var/www/virtual/domain/sub/htdocs>

    Options FollowSymLinks

    DirectoryIndex index.php

    AllowOverride All

    Options +ExecCGI

    FCGIWrapper /var/www/fcgi/sub.domain/php-fcgi-starter

    DirectoryIndex index.html index.xhtml index.htm

    Require all granted

    <Files *m3u>

    ForceType application/x-httpd-php

    </Files>

    </Directory>

    Alias /cgi-bin/ /var/www/virtual/domain/sub/cgi-bin/

    <Directory /var/www/virtual/domain/sub/cgi-bin>

    AllowOverride AuthConfig Indexes Limit Options=Indexes,MultiViews \

    Fileinfo=RewriteEngine,RewriteOptions,RewriteBase,RewriteCond,RewriteRule Nonfatal=Override

    DirectoryIndex index.cgi index.pl index.py index.rb

    Options FollowSymLinks ExecCGI

    AddHandler cgi-script .cgi .pl .py .rb

    Require all granted

    </Directory>

    <IfModule mime_module>

    AddHandler application/x-httpd-php .m3u

    </IfModule>

    Include /etc/apache2/imscp/sub.domain.conf

    </VirtualHost>



    /var/www/virtual/domain/sub/htdocs/

    .htaccess:


    AddHandler application/x-httpd-php .m3u

    AddType application/x-httpd-php70 .m3u

    AddType application/x-httpd-php .m3u

  • For a little help to understand I translate your question:

    I want tu run a file named example.m3u like a normal example.php

    How its possible in I-mscp system?

  • At this moment there is no GUI-feature for this, nor is this a planned feature as far as I know.

    You could use a listener to add this to config file, but begin by testing if that works by editing your config, or attempt it with a .htaccess.

  • theemstra

    Added the Label question