可通过Internet和Intranet访问的面条

问题描述 投票:-1回答:2

我们设置了Fortinet,以通过公共IP将内部Moodle页面重定向到Internet。我们的Moodle页面在IIS上运行。我所做的就是将config.php更改为以下内容:

$CFG->wwwroot = 'http://'.$_SERVER['HTTP_HOST'];

在内部它可以正常工作,但是当从Internet打开页面时,出现错误:ERR_TOO_MANY_REDIRECTS我创建了一个示例页面/test.php,它可以正常打开。

我尝试注释掉redirect(“ index.php?sessionstarted = 1&lang = $ CFG-> lang”);从moodle \ admin \ index.html中删除,并按照建议的here从moodledata \ sessions中删除会话文件,但是它不起作用。

moodle
2个回答
0
投票

尝试替换

$CFG->wwwroot = 'http://'.$_SERVER['HTTP_HOST'];

with

$CFG->wwwroot = 'http://yoursitename.com';

0
投票

$CFG->wwwroot = 'http://'.$_SERVER['HTTP_HOST'];更改为$CFG->wwwroot = 'http://' . $_SERVER['SERVER_NAME'];至今为止。

© www.soinside.com 2019 - 2024. All rights reserved.