General developer forum

Moodle URL redirects to localhost

 
Picture of Bilal Amir
Moodle URL redirects to localhost
 

Moodle version - 3.3

WAMP Server - 3.1

Running on Windows Server 2008 R2 Enterprise 64bit with 6GB RAM.

I installed my second Moodle system on a different server (virtual). The installation went alright. Created the admin account and changed the URL in config.php ($CFG->wwwroot).

I also added the IP address of the system to the host file (found in C:\Windows\System32\drivers\etc) and linked it to the same URL given in wwwroot (http://mymoodle.com).

However everytime I enter the URL mymoodle.com in the browser, it opens up localhost. And when I type mymoodle.com/moodle, it opens the moodle site. And the site is loaded without the theme.

I can understand what the problem is but anything I try doesn't seem to work. Any ideas on how to solve this ? It's urgent.


 
Average of ratings: -