Sponsor:

Server and Web Integrator
Link:
Kloxo-MR logo
6.5.0 or 7.0.0
Click for "How to install"
Donation/Sponsorship:
Kloxo-MR is open-source.
Donate and or Sponsorship always welcome.
Click to:
Click Here
Please login or register. 2024-05-11, 09:51:16

Author Topic: Parsing heml as php  (Read 3430 times)

0 Members and 1 Guest are viewing this topic.

Offline azzureal

  • Master
  • **
  • Posts: 420
  • Karma: +1/-0
    • View Profile
Parsing heml as php
« on: 2015-10-12, 18:56:34 »
My old kloxo mr can use html as php.

I modified conf file in php-fpm.d and apach domain conf file.

My new installed system has changed.

So I can't find AddType in domain conf.

How can I use html as php?

Offline MRatWork

  • Administrator
  • The Elite
  • *****
  • Posts: 15,807
  • Karma: +119/-11
  • Gender: Male
    • View Profile
    • MRatWork Forum
Re: Parsing heml as php
« Reply #1 on: 2015-10-12, 19:40:51 »
It's depend on web server type (pure apache or proxy).
..:: MRatWork (Mustafa Ramadhan Projects) ::..
-- Server/Web-integrator - Web Hosting (Kloxo-MR READY!) --

Offline azzureal

  • Master
  • **
  • Posts: 420
  • Karma: +1/-0
    • View Profile
Re: Parsing heml as php
« Reply #2 on: 2015-10-13, 01:55:05 »
I am using php-fpm.

I How can I parse html as php?


Offline MRatWork

  • Administrator
  • The Elite
  • *****
  • Posts: 15,807
  • Karma: +119/-11
  • Gender: Male
    • View Profile
    • MRatWork Forum
Re: Parsing heml as php
« Reply #3 on: 2015-10-13, 02:10:27 »
I mean using lighttpd, nginx, hiawatha, apache or proxy need different 'addtype'.
..:: MRatWork (Mustafa Ramadhan Projects) ::..
-- Server/Web-integrator - Web Hosting (Kloxo-MR READY!) --

Offline azzureal

  • Master
  • **
  • Posts: 420
  • Karma: +1/-0
    • View Profile
Re: Parsing heml as php
« Reply #4 on: 2015-10-13, 02:12:33 »
Here my sysinfo

A. Kloxo-MR: 7.0.0.b-2015100801
   - Web: hiawatha-9.14.0-f.6.mr.el6.x86_64
   - PHP: php54s-5.4.45-1.ius.el6 (cgi mode)
B. Plateform:
   - OS: CentOS release 6.7 (Final) x86_64
   - Hostname: cocks.hostingis.com
C. Services:
   1. MySQL: MariaDB-server-10.0.21-1.el6.x86_64
   2. PHP:
      - Branch: php53u-cli-5.3.29-1.ius.el6.x86_64
      - Multiple:
        * php52m-5.2.17-102.mr.el6
        * php53m-5.3.29-1.ius.el6
        * php54m-5.4.45-1.ius.el6
        * php55m-5.5.29-1.ius.el6
        * php56m-5.6.13-1.ius.el6
      - Used: --Use PHP Branch--
   3. Httpd: httpd-2.2.31-1.mr.el6.x86_64
      - PHP Type: php-fpm_event
   4. Lighttpd: --uninstalled--
   5. Hiawatha: --unused--
   6. Nginx: --uninstalled--
   7. Cache: --uninstalled--
   8. Dns: --uninstalled--
   9. Qmail: qmail-toaster-1.03-1.3.55.mr.el6.x86_64
      - with: courier-imap-toaster-4.1.2-1.3.18.mr.el6.x86_64

I modified .htacces.
Error 500 - Internal Server Error

Offline MRatWork

  • Administrator
  • The Elite
  • *****
  • Posts: 15,807
  • Karma: +119/-11
  • Gender: Male
    • View Profile
    • MRatWork Forum
Re: Parsing heml as php
« Reply #5 on: 2015-10-13, 02:28:23 »
Because using apache with php-fpm, try copy domains.conf.tpl to custom.domains.conf.tpl inside /opt/configs/apache/tpl and then modified '<FilesMatch \.php$>' to '<FilesMatch \.(php|heml)$>' in this custom file. After that, run 'sh /script/fixweb; sh /script/restart-web -y'.
..:: MRatWork (Mustafa Ramadhan Projects) ::..
-- Server/Web-integrator - Web Hosting (Kloxo-MR READY!) --

Offline azzureal

  • Master
  • **
  • Posts: 420
  • Karma: +1/-0
    • View Profile
Re: Parsing heml as php
« Reply #6 on: 2015-10-13, 02:46:55 »
I tried it, but doesn't parsing as php.


Offline MRatWork

  • Administrator
  • The Elite
  • *****
  • Posts: 15,807
  • Karma: +119/-11
  • Gender: Male
    • View Profile
    • MRatWork Forum
Re: Parsing heml as php
« Reply #7 on: 2015-10-13, 02:55:14 »
Inform here your domain where you need heml
..:: MRatWork (Mustafa Ramadhan Projects) ::..
-- Server/Web-integrator - Web Hosting (Kloxo-MR READY!) --

Offline azzureal

  • Master
  • **
  • Posts: 420
  • Karma: +1/-0
    • View Profile
Re: Parsing heml as php
« Reply #8 on: 2015-10-13, 03:15:11 »

Offline azzureal

  • Master
  • **
  • Posts: 420
  • Karma: +1/-0
    • View Profile
Re: Parsing heml as php
« Reply #9 on: 2015-10-13, 03:23:50 »
I added <FilesMatch "\.(htm|html|php)$">
AddType application/x-httpd-php .html
</FilesMatch> in .htaccess

it works.

Offline MRatWork

  • Administrator
  • The Elite
  • *****
  • Posts: 15,807
  • Karma: +119/-11
  • Gender: Male
    • View Profile
    • MRatWork Forum
Re: Parsing heml as php
« Reply #10 on: 2015-10-13, 03:28:41 »
Yes, because file extension like you said is 'heml' (not 'html' or 'htm'). That it.
..:: MRatWork (Mustafa Ramadhan Projects) ::..
-- Server/Web-integrator - Web Hosting (Kloxo-MR READY!) --

Offline azzureal

  • Master
  • **
  • Posts: 420
  • Karma: +1/-0
    • View Profile
Re: Parsing heml as php
« Reply #11 on: 2015-10-13, 04:23:29 »
Thanks. Works fine.

But I meet another problem.

Chareset is not work.

I am using euc-kr and UTF-8.

All euc-kr charset is not work, only UTF-8.

I had solved this problem before with upcp -y. But now not work.

This may last proble to upgrade from Kloco off.

Offline MRatWork

  • Administrator
  • The Elite
  • *****
  • Posts: 15,807
  • Karma: +119/-11
  • Gender: Male
    • View Profile
    • MRatWork Forum
Re: Parsing heml as php
« Reply #12 on: 2015-10-13, 04:42:25 »
Apache use utf-80 by default.
..:: MRatWork (Mustafa Ramadhan Projects) ::..
-- Server/Web-integrator - Web Hosting (Kloxo-MR READY!) --

Offline azzureal

  • Master
  • **
  • Posts: 420
  • Karma: +1/-0
    • View Profile
Re: Parsing heml as php
« Reply #13 on: 2015-10-13, 04:59:35 »
I know. So I am using metateg charset.
It works OK.

So i am solving to put in header('Content-Type: text/html; charset=UTF-8');

It is difficult to modify all.


 


Top 10 Social Networking:    Facebook    Twitter    LinkedIn    Pinterest    Google Plus    Tumblr    Instagram    VK    Flickr    Vine
Click Here

Page created in 0.031 seconds with 19 queries.

web stats analysis