Installation
This page describes how the Mobile Detector example application can be installed on Windows 2003 or Windows XP. Please ensure you've downloaded the latest install zip file from the .NET Mobile API product page.
Minimum Requirements
A mobile device emulator. Our favourites can be found here.
PC running Windows XP or Windows 2003 Server. (Note: Later versions of Vista and Windows 2008 Server can also be used but the installation instructions will vary).
.NET Framework Version 2.0 or later.
Step 1 - Extract Download
Log on as Administrator and extract the files contained in the zip file to a location that allows you to execute them as Administrator.
Step 2 - Check your Mobile Device Emulator
Confirm your emulator is working by opening http://51degrees.co.uk with the emulator.
Step 3 - Create a Web Site
Before running the installation we need to create a web site (or virtual directory) ready to be configured with the Detector example. If you okay using the Default Web Site you can skip this step and use Default Web Site and port number 80 in Step 4, 5 and 6.
Open Internet Information Services (IIS) Manager from the Adminstrative Tools. If IIS is not available then you'll need to install IIS from the Windows installation media.
Right click the Web Sites folder and choose New -> Web Site... The following dialogue will appear.

Enter the name of the web site you're creating under Description. Remember what you type as you'll need to select it from a drop down list in Step 4.
Select Next and you'll see the following screen.

Enter a port number that will not conflict with any other service of web site already running on the machine. If the Default Web Site is still installed then you'll need to use a number other than 80. In this example we're using port 88. Ensure you remember the port number as it'll be needed in Step 5 and 6.
If you'd like to use a unique web site address you could continue to use port 80 and enter the domain name in the Host header. Your browser will need to resolve this domain name either via the local hosts file or through DNS resolution.
Select Next once you're happy with the setup and you'll see the following dialogue.

Create an empty directory where you'd like the content of the web site stored and enter this path into the form. Ensure the Allow anonymous access to this web site check box is enabled. If you're not using a fresh directory created under Inetpub also ensure the directory has read and execute access for the application pool you intend to use. When you're happy with the path select Next to move to the following screen.

Check the Run scripts (such as ASP) check box and press Next to complete web site setup. If all has gone correctly you should see the following dialogue.

Step 4 - Install Web Site
As Administrator execute the InstallDetector installer. You should see the following screen.

Select Next and you'll see the following screen. If you've already installed the web site you'll see a dialogue box requesting you uninstall the previous version before continuing.

Under Site select the web site you created in Step 3. There should be no need to change other settings unless you're creating a Virtual Directory or use multiple Application Pools. Select Next to continue the installation process and complete installation. Successful install is confirmed when the following screen is presented.

Step 5 - Confirm Installation
Using the standard desktop browser on your machine enter the web address for the web site. If you used a different port number in Step 2 this will be http://localhost:portnumber where portnumber is the value you entered. If the site is working correctly you'll see a web page similar to the following.

If you received errors follow the standard Microsoft documentation to resolve them before continuing. Most errors are caused by the Application Pool identity not having sufficient access to the directory your web site is installed in or another service conflicting with the chosen port.
When you access the site from a desktop or laptop you'll find a link to check User Agent strings.
Step 6 - Browse from a Mobile Emulator
Using the mobile device emulator enter precisely the same address as that used in Step 5. The web site will detect the use of a mobile device and redirect it to a different landing or home page. Using Openwave you'll see the following screen.

Conclusion
We hope you've found this example interesting and shown that it is relatively simple to provide both traditional web pages and mobile web pages on the same web site with the same host name. Your business will benefit from knowing all the money being spent on marketing your business and web site will not need to be altered when you need to deploy to mobile devices.