###前提・実現したいこと
さくらレンタルサーバーを使ってhttp→httpsへのリダイレクト処理を実行したところ上手くいきませんでした。
###発生している問題・エラーメッセージ
Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator, ....and inform them of the time the error occurred, and anything you might have done that may have caused the error.
More information about this error may be available in the server error log.
エラーメッセージ
###該当のソースコード
<IfModule mod_rewrite.c> RewriteEngine On RewriteCond %{SERVER_PORT} 80 RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L] </IfModule>
###試したこと
リダイレクト処理のサンプルコードをいくつか探してみたのですが全部ダメで上記のメッセージが出てしまいます。そこでさくらのDBのエラーログを調査したところ「PHP Deprecated: Comments starting with '#' are deprecated in 」の表示がでていたのでphp.iniの中を検索したのですが # から始まる箇所がいくつかあってどこを修正すればいいのかわかりませんのでよろしくお願いします。
###補足情報(言語/FW/ツール等のバージョンなど)
より詳細な情報
回答2件
あなたの回答
tips
プレビュー