UPDATE
I found a solution as IIRF
. please read the accepted answer
I haven't worked with Windows Server / IIS before and thus I am finding it a little difficult to deal with it. I even don't know if both of them are the same thing.
The scenario is like this:
I have two versions of one site, a .com one for PC viewers, a .mobi one for mobile phones. I want to redirect all the mobile phone (smartphone) user coming to .com site to .mobi site. I'll be using wurfl for detecting the accessing device's type, and all of this stuff works pretty fine with the php script I wrote.
Since the home page of the site is a plain html, I can't use any PHP script in it.
I also can't change the page to a PHP script since default.htm
is needed by the SEO guys, I don't know why.
I was wishing to have web.config
(or anything else) written the way that it rewrites all the URL requests coming to default.htm
to default.php
where I can make the detector script work, and this script further decides where to send the user.
I don't know anything about web.config
, I just found out that its similar to .htaccess
Please tell me something about it. The server has various sites and its only one site that we would want to have this functionality. Should I put the web.config
inside the folder of this particular site?
UPDATE
I found out by the answers and the comments that web.config
works only with the ASP.NET applications while I don't have any ASP.NET environment set at the server.
I also can't use the IIS URLRewrite module since its works with IIS7+ and I have IIS 6.0.
Is there any way out?