CPIサーバーでphpを動作させる:解決

CPIにて幾つかサイト運用開始したのやけど、自由に扱うにはちょいと作法がいる。
参考:PHPを動作させる
http://hanazono-news.blogspot.com/2010/08/cpiphp.html
htdocsのルート上でhtaccessとして以下記述しておく。

PHPを動作させる
AddHandler x-httpd-php528 .php

php.iniを追加できるように
suPHP_ConfigPath /home/アカウント/html/

もいっちょ念のためファイルのアクセス拒否
<Files ~ “^(\.htaccess|\.htpasswd|php\.ini|.*\.sql|.*\.log|.*\.cron|.*\.inc|.*\.phps|.*\.yml)$”>
deny from all
</Files>

あとはmod_rewriteのおまじない
Options +FollowSymLinks

これでよし。

コメントを残す

メールアドレスが公開されることはありません。 が付いている欄は必須項目です

To respond on your own website, enter the URL of your response which should contain a link to this post's permalink URL. Your response will then appear (possibly after moderation) on this page. Want to update or remove your response? Update or delete your post and re-enter your post's URL again. (Find out more about Webmentions.)