Map localhost to external domain

Amanda Ford asked on July 10, 2014 11:05

I am trying to forward my localhost site to somesite.com. I get the error message: Bad request - Invalid Hostname.

I am using IIS Express and I updated the applicationhost.config file binding protocol from :8080:localhost to the following:

Any ideas on what I'm doing wrong?

Recent Answers


Pavel Janečka answered on July 12, 2014 06:36

Hi Amanada,

it seems that part of your message got deleted, would you mind reposting it? In order to prevent sanitization you might want to introduce each line of your code by the tab character.

With the info you entered I would suppose you want to be redirected to somesite.com upon entering http://localhost within your web browser, which can be achieved by admin-edditing %systemroot%\system32\drivers\etc\hosts. However, I'm not sure you wanted that, can you please elaborate?

Best regards,
Pavel

0 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.