links gets generated as http://127.0.0.1/

links gets generated as http://127.0.0.1/

by Caroline Olivia Frank -
Number of replies: 3

In every email sent from the moodle admin, like messages to the students and information about materials with a link to it and information about login, every link gets sent as http://127.0.0.1/ (like http://127.0.0.1/mod/forum/discuss.php?d=2#p2).

Also emails from moodle, like updates, also sends this specific link.
The moodle is set up by a Bitnami image with AWS.

It looks like it is some property that defines the site URL, that doesn't work correctly?

I really hope somebody can help me.

Average of ratings: -
In reply to Caroline Olivia Frank

Re: links gets generated as http://127.0.0.1/

by Jez H -
127.0.0.1 is the "localhost" address, i.e. your server uses that address for "itself".

If you installed moodle from the server itself it may have picked that address up at some point, but it seems a bit weird if you can still access via the domain.

I think my starting point would be to search the admin settings (using search box in site admin block) for "127.0.0.1" to check that has not been applied to any of the Moodle settings. I would also take a look at config.php to make sure there is not an issue there.
In reply to Caroline Olivia Frank

Re: links gets generated as http://127.0.0.1/

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
Is it possible that this Moodle was first installed as a "localhost" installation, means Moodle responds only to a browser running in the computer it was installed, and then moved to the Internet? Then there are still old links in the database. Read https://docs.moodle.org/en/Moodle_migration#Update_links_containing_wwwroot_in_the_database.

WARNING: Read all the warning it generates carefully. A misstep can make your Moodle unusable!