So what might be the problem with:
- navigating to localhost is redirected to localhost/localhost and caused 404
- navigating to localhost/install.php is redirected to localhost/admin/localhost and causes 404 as well
what should I check?
So what might be the problem with:
what should I check?
My best guess would be that you've got an existing config.php in the top level of your Moodle source code folder and this has the following line with the location you're being incorrectly redirected to:
$CFG->wwwroot = 'http://localhost/localhost';
You probably need to change this to:
$CFG->wwwroot = 'http://localhost';
File config.php is probably in C:\inetpub\wwwroot.
However, you wouldn't normally have an existing config.php (the file containing key configuration information about your site) before you've installed Moodle unless you've either manually created this or have already tried to install Moodle unsuccessfully.