Hi Hanzie,
It is possible that Gallery 2 has a Web.config file even if it is a php app. I would look for it in the gallery2 folder.
I recommend study the links in my first reply on this thread, it sounds like a conflict of Web.config files, the solution is in the links from the faq page that involve using <location element in Web.config.
Hope that helps,
Joe