IIS has a URL rewrite module. It essentially allows you to define an inbound url rool and determine what the out bound url is.
[
^]
I am still really confused as to the problem that you're facing. Why didn't you just make your url's relative that way it doesn't matter where your website is deployed too? At any rate I think a find and replace could make everything relative, which would make things a lot easier... wouldn't it?