$base_path is not added to AJAX URL request in login form
First off, in the settings.php file you should have an example of http://www.example.com and a comment there, saying that you should not append a trailing slash.
Next, in your case looks like http://localhost would be the correct value of $base_url, if any - try hashing out $base_url line to see if the site is fine without it - as it might be.