I have a shell script , which I am executing via a PHP, which in turn executed from a html page.

Whereas PHP script is not getting executed from the html.

PHP script is working fine when executing from the server.

Please be informed ownership is correct.

Please suggest a way out.

Thanks in advance.

Regards,
Arnab

add this to your .htaccess file

Apache2 @ Ubuntu/Debian: use this directive

 AddType application/x-httpd-php .html .htm

If your are running PHP as CGI (probably not the case), you should write instead:

  AddHandler application/x-httpd-php .html .htm 

Thanks for replying.

I am using rhel server. Then what I need to update as AddType ???

Just add the AddType application/x-httpd=php .html .htm then the pages will work. It will make the server think that HTML/HTM pages are PHP and read the scripting you added.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.