1
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

ECCUBE3で後からSSLを導入した際にしたこと(html/indxe.php省略)

Posted at

ECCUBE3系でhtml/index.phpを省略し、運営していたのですが途中でSSLを導入することになったのですが、いろいろ困って解決したのでメモ

■ 管理画面にアクセスするときhttpにリダイレクトされる場合
/autoload.php の先頭に
if (isset($_SERVER['HTTP_X_SAKURA_FORWARDED_FOR'])) {
$_SERVER['HTTPS'] = 'on';
$_ENV['HTTPS'] = 'on';
$_SERVER['HTTP_HOST'] = 'ドメイン名';
$_SERVER['SERVER_NAME'] = 'ドメイン名';
$_ENV['HTTP_HOST'] = 'ドメイン名';
$_ENV['SERVER_NAME'] = 'ドメイン名';
}
を追記。

■いろいろ設定していたせいでhtaccessでhttpからhttpsにリダイレクトすることができない

/app/config/eccube/config.yml

force_ssl: null を force_ssl: 1 に変更。

自分は技術不足なため、まだまだ情報が少ないECCUBE3は辛いっす

1
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?