30
Windows Server 2008 (IIS 7.5) - FAQ How do I deploy a Visual Studio 2010 Web Application Project using Web Deploy? How to connect with FTP over SSL using the FileZilla FTP client Where did my IIS Manager settings go? Log into IIS Manager for Remote Administration How can I access WebDAV? How to send email in ASP.NET 2.0 ASP .NET 4.0 application error: Unrecognized attribute “targetFramework” Install applications using Web Platform Installer How can I disable anonymous access to a folder and its subfolders in IIS7.5? How to redirect a subdomain to a subfolder Why can’t I delete all files from WebDAV? How to add Google Analytics to your website

Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

  • Upload
    leminh

  • View
    235

  • Download
    5

Embed Size (px)

Citation preview

Page 1: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

Windows Server 2008 (IIS 75) - FAQ

How do I deploy a Visual Studio 2010 Web Application Project using Web

Deploy

How to connect with FTP over SSL using the FileZilla FTP client

Where did my IIS Manager settings go

Log into IIS Manager for Remote Administration

How can I access WebDAV

How to send email in ASPNET 20

ASP NET 40 application error Unrecognized attribute ldquotargetFrameworkrdquo

Install applications using Web Platform Installer

How can I disable anonymous access to a folder and its subfolders in IIS75

How to redirect a subdomain to a subfolder

Why canrsquot I delete all files from WebDAV

How to add Google Analytics to your website

How do I deploy a Visual Studio 2010 Web Application Project using Web Deploy

Important The following instructions apply only to Web Application Projects in

Visual Studio not Web Site

Web Deploy is a new method to publish your web application Note that

Web Deploy is only available for web sites hosted on Windows 2008 servers

In order to use the web deploy method with Visual Studio 2010 you must activate IIS

Manager access in MyAccount control panel (User Manager) if you have not already

done so

To publish your web application using Web Deploy

Open the project in Visual Studio 2010

Click Build -gt Publish This will bring up the Publish Web dialog box

Change the Publish Method to Web Deploy

In the Service URL field enter

https[webserver]active24com8172MsDeployaxd ([webserver] is the

actual server name for example ho01-is-s701)

In the Siteapplication field enter [domainName][subdirectory] eg

examplecomapp1 Replace [subdirectory] with the directory you wish to

publish the application to

Check Mark as IIS application on destination

Check Allow untrusted certificate

In the username field enter your Web Deploy username found in MyAccount

control panel

In the password field enter your password

Click Publish

How to connect with FTP over SSL using the FileZilla FTP client

Windows 2008 R2IIS 75 allows a secure FTP connection via FTP over SSL Note

that this is not the same as SFTP (FTP via SSH)

1 Click Open Site Manager

2 Click the New Site button and name the site

3 Fill in the following fields

a Logon type normal

b Host enter either your domain name or alternate FTP address

c Username ftpexamplecom|30030895Aexamplecom

d Password enter the password for this user

e Server type ldquoFTPES ndash FTP over explicit TLSSSLrdquo

4 Click Connect

Where did my IIS Manager settings go

There are two ways this could have happened

1) Yoursquove deleted the webconfig file

2) Yoursquove replaced the webconfig file with your own

The majority of the IIS Manager settings are stored in your individual webconfig file

This means that if you delete the webconfig file either by accident or on purpose

settings like anonymousbasic authentication default documents HTTP Errors etc

will be reset to the server default

You should also be aware that if you upload your own webconfig file you might

break your website by overwritingremoving features yoursquove set via the control panel

or IIS Remote Manager or you could end up trying to utilize features not allowed

under the current server configuration rendering the entire website unavailable

Log into IIS Manager for Remote Administration

The IIS Manager for Remote Administration is a tool from Microsoft which

provides administrators with the ability to securely manage IIS 75 web sites from a

remote computer

The IIS Manager can be downloaded from Microsoft The link can be found in

MyAccount

Log into MyAccount using your username and password In left menu go to

Windows Web and Get Started The link for IIS Manager and login details are

provided from the section IIS Manager for Remote Administration

The User Manager has an option for turning access to IIS Manager on or off Go to

Windows Web and User Manager to make sure it is on When the checkbox is

checked like image below the user has access to IIS Manager

After downloading and installing the tool it can be started from shortcut in Start-

menu The program will be called Internet Information Services (IIS) 7 Manager

Add a new connection to the site using the Connect to a Site function

Enter Server Name and Site name These settings can be found in MyAccount in Get

Started Click Next

Enter User name and Password These where sent to your domains administrator in

an e-mail Click Next

If the username or password is wrong you will get a warning about this after clicking

Next

The first time you add a new web site you might get this dialog box regarding

additional features which can be installed It is recommended to install all features

Check the box to the left of each feature and click OK The features will now be

installed

Finally enter a name for the web site connection We recommend using domain

name Click Finish

The site is now available for administration

How can I access WebDAV

WebDAV let you access your website over the https protocol as a network drive on

your local computer

First make sure your site and user account has been setup correctly in MyAccount

Control Panel

In MyAccount control panel (IIS Admin) make sure you have activated WebDAV

access for your site

In MyAccount control panel (User Manager) make sure you have activated WebDAV

access for your user

Now you are ready to access WebDAV from your Operating System If you are using

Windows you access WebDAV by clicking ldquoComputerrdquo in your Explorer window

and then choose ldquoMap network driverdquo

For security reasons we only allow WebDAV to be accessed using SSL so the https

protocol is required and you must use the ldquossl-encryptedcomrdquo shared SSL domain

we provide you in the MyAccount control panel (Get Started)

Select a drive letter you would like mapped to your site (ie Z)

As a ldquoFolderrdquo enter your ldquoWebDAV Hostnamerdquo found in MyAccount control

panel ie https[id]ssl-encryptedcom

Check ldquoConnect using different credentialsrdquo

Enter you Username and Password found in MyAccount control panel

You should now have Z connected to your site as a network drive

How to send email in ASPNET 20

Since version 20 ASPNET has a built in class (SystemNetMail) to send email See

the following code as example

C ASPNET

using SystemNetMail [hellip] MailMessage objEmail = new MailMessage( fromexamplecom toexamplecom This is the Subject This is the Body) objEmailPriority = MailPriorityNormal SmtpClient SMTPServer = new SmtpClient(localhost) try SMTPServerSend(objEmail) ResponseWrite(Email sent sucessfully) catch (Exception exc) ResponseWrite(Send failure + excToString())

VB ASPNET Imports SystemNetMail [hellip] Dim strFrom = fromexamplecom Dim strTo = toexamplecom Dim MailMsg As New MailMessage(New MailAddress(strFromTrim()) New MailAddress(strTo)) MailMsgSubject = This is the Subject MailMsgBody = This is the Body MailMsgPriority = MailPriorityNormal Dim SmtpMail As New SmtpClient SmtpMailHost = localhost Try SmtpMailSend(MailMsg) ResponseWrite(Email sent sucessfully) Catch exc As Exception ResponseWrite(excMessage) End Try

PHP ltphp

$to = toexamplecom

$subject = This is the subject

$body = This is the Body

$headers = From fromexamplecomrn

X-Mailer php

if (mail($to $subject $body $headers))

echo(ltpgtEmail sent successfullyltpgt)

else

echo(ltpgtMessage delivery failedltpgt)

gt

ASP NET 40 application error Unrecognized attribute ldquotargetFrameworkrdquo

If you find the following error when you attempt to open your web application

Description An error occurred during the processing of a configuration file required

to service this request Please review the specific error details below and modify your

configuration file appropriately

Parser Error Message Unrecognized attribute targetFramework Note that attribute

names are case-sensitive

The error indicates that your account is configured to run with the ASPNET 20

framework but your application is an ASPNET 40 application

To correct this simply login into MyAccount and under Windows Web IIS Admin

select 40 in the dropdown list named ldquoASPNET Versionrdquo as shown in the screen

below then click ldquoSet IIS propertiesrdquo

Install applications using Web Platform Installer

The Web Platform Installer provides easy installation of several popular web

applications to your web site This demonstration will show installation of a blog

system called Wordpress

Most applications requires a database If your product does not contain a database you

can contact Sales to get this If your database is not created you can do this from the

SQL section in MyAccount

The Web Platform Installer is a part of the IIS Manager for Remote

Administration tool

Web Platform Installer is a separate download from Microsoft The link to this is

located in MyAccount Windows Web Get Started

To start the Web Platform Installer open IIS Manager for Remote

Administration and go to Management section Double-click on the icon

The installer will use some seconds to load before starting

Choose either Whatrsquos new or Web Applications for browsing the applications

available for install

Web Applications has a several categories with types of applications

Click the information-icon to the right of application title to view more detailed

information about an application

This demonstration will install Wordpress from the Blogs section Click the Install

button when application has been chosen

A popup will list the application you have selected Click I Accept and the web

application will be downloaded

The next steps require information about your web site and database This information

can be found in MyAccount Passwords are sent to your domain names administrator

by e-mail

First enter a application name

To install the application on your web site root leave this box empty You will then

get a warning about the destination folder not being empty and you have to confirm to

overwrite existing files

Enter application name to install site in sub-folder Click Continue

The next and final step requires information about database passwords and other

important data

Important information

Some applications requires MSSQL and others MySQL database The Web

Platform Installer will show which database is required You need to go to the

correct product in MyAccount for information

In our example Wordpress requires MySQL

In the option Create a new or use an existing database it is important that you

choose Use existing database

Fill in information about database user password server location etc Click

Continue

If you get an error message about missing components (eg MySQL Connector for

Net) click the OK button

The site will be installed on web and database server and a confirmation page will be

displayed when completed

Click Launch to see site in browser and Finish to return to Web Platform Installer

If you want to install more than one application at once you can click more

checkboxes and then click Install The installation wizard will ask for information

required for each site chosen

How can I disable anonymous access to a folder and its subfolders in IIS75

It is possible to disable anonymous access to a specific folder and its subfolders To

do so simply create a webconfig file in that folder (or edit the existing one) with the

lines provided below It is required that Windows Authentication is enabled for

the site This must be done using the IIS 7 Manager ltxml version=10gt ltconfigurationgt ltsystemwebgt ltauthorizationgt ltdeny users= gt ltallow users=30030895Aexamplecomgt ltauthorizationgt ltsystemwebgt ltconfigurationgt

This way only the admin user specified would be able to access that folder and its

subfolders

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 2: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

How do I deploy a Visual Studio 2010 Web Application Project using Web Deploy

Important The following instructions apply only to Web Application Projects in

Visual Studio not Web Site

Web Deploy is a new method to publish your web application Note that

Web Deploy is only available for web sites hosted on Windows 2008 servers

In order to use the web deploy method with Visual Studio 2010 you must activate IIS

Manager access in MyAccount control panel (User Manager) if you have not already

done so

To publish your web application using Web Deploy

Open the project in Visual Studio 2010

Click Build -gt Publish This will bring up the Publish Web dialog box

Change the Publish Method to Web Deploy

In the Service URL field enter

https[webserver]active24com8172MsDeployaxd ([webserver] is the

actual server name for example ho01-is-s701)

In the Siteapplication field enter [domainName][subdirectory] eg

examplecomapp1 Replace [subdirectory] with the directory you wish to

publish the application to

Check Mark as IIS application on destination

Check Allow untrusted certificate

In the username field enter your Web Deploy username found in MyAccount

control panel

In the password field enter your password

Click Publish

How to connect with FTP over SSL using the FileZilla FTP client

Windows 2008 R2IIS 75 allows a secure FTP connection via FTP over SSL Note

that this is not the same as SFTP (FTP via SSH)

1 Click Open Site Manager

2 Click the New Site button and name the site

3 Fill in the following fields

a Logon type normal

b Host enter either your domain name or alternate FTP address

c Username ftpexamplecom|30030895Aexamplecom

d Password enter the password for this user

e Server type ldquoFTPES ndash FTP over explicit TLSSSLrdquo

4 Click Connect

Where did my IIS Manager settings go

There are two ways this could have happened

1) Yoursquove deleted the webconfig file

2) Yoursquove replaced the webconfig file with your own

The majority of the IIS Manager settings are stored in your individual webconfig file

This means that if you delete the webconfig file either by accident or on purpose

settings like anonymousbasic authentication default documents HTTP Errors etc

will be reset to the server default

You should also be aware that if you upload your own webconfig file you might

break your website by overwritingremoving features yoursquove set via the control panel

or IIS Remote Manager or you could end up trying to utilize features not allowed

under the current server configuration rendering the entire website unavailable

Log into IIS Manager for Remote Administration

The IIS Manager for Remote Administration is a tool from Microsoft which

provides administrators with the ability to securely manage IIS 75 web sites from a

remote computer

The IIS Manager can be downloaded from Microsoft The link can be found in

MyAccount

Log into MyAccount using your username and password In left menu go to

Windows Web and Get Started The link for IIS Manager and login details are

provided from the section IIS Manager for Remote Administration

The User Manager has an option for turning access to IIS Manager on or off Go to

Windows Web and User Manager to make sure it is on When the checkbox is

checked like image below the user has access to IIS Manager

After downloading and installing the tool it can be started from shortcut in Start-

menu The program will be called Internet Information Services (IIS) 7 Manager

Add a new connection to the site using the Connect to a Site function

Enter Server Name and Site name These settings can be found in MyAccount in Get

Started Click Next

Enter User name and Password These where sent to your domains administrator in

an e-mail Click Next

If the username or password is wrong you will get a warning about this after clicking

Next

The first time you add a new web site you might get this dialog box regarding

additional features which can be installed It is recommended to install all features

Check the box to the left of each feature and click OK The features will now be

installed

Finally enter a name for the web site connection We recommend using domain

name Click Finish

The site is now available for administration

How can I access WebDAV

WebDAV let you access your website over the https protocol as a network drive on

your local computer

First make sure your site and user account has been setup correctly in MyAccount

Control Panel

In MyAccount control panel (IIS Admin) make sure you have activated WebDAV

access for your site

In MyAccount control panel (User Manager) make sure you have activated WebDAV

access for your user

Now you are ready to access WebDAV from your Operating System If you are using

Windows you access WebDAV by clicking ldquoComputerrdquo in your Explorer window

and then choose ldquoMap network driverdquo

For security reasons we only allow WebDAV to be accessed using SSL so the https

protocol is required and you must use the ldquossl-encryptedcomrdquo shared SSL domain

we provide you in the MyAccount control panel (Get Started)

Select a drive letter you would like mapped to your site (ie Z)

As a ldquoFolderrdquo enter your ldquoWebDAV Hostnamerdquo found in MyAccount control

panel ie https[id]ssl-encryptedcom

Check ldquoConnect using different credentialsrdquo

Enter you Username and Password found in MyAccount control panel

You should now have Z connected to your site as a network drive

How to send email in ASPNET 20

Since version 20 ASPNET has a built in class (SystemNetMail) to send email See

the following code as example

C ASPNET

using SystemNetMail [hellip] MailMessage objEmail = new MailMessage( fromexamplecom toexamplecom This is the Subject This is the Body) objEmailPriority = MailPriorityNormal SmtpClient SMTPServer = new SmtpClient(localhost) try SMTPServerSend(objEmail) ResponseWrite(Email sent sucessfully) catch (Exception exc) ResponseWrite(Send failure + excToString())

VB ASPNET Imports SystemNetMail [hellip] Dim strFrom = fromexamplecom Dim strTo = toexamplecom Dim MailMsg As New MailMessage(New MailAddress(strFromTrim()) New MailAddress(strTo)) MailMsgSubject = This is the Subject MailMsgBody = This is the Body MailMsgPriority = MailPriorityNormal Dim SmtpMail As New SmtpClient SmtpMailHost = localhost Try SmtpMailSend(MailMsg) ResponseWrite(Email sent sucessfully) Catch exc As Exception ResponseWrite(excMessage) End Try

PHP ltphp

$to = toexamplecom

$subject = This is the subject

$body = This is the Body

$headers = From fromexamplecomrn

X-Mailer php

if (mail($to $subject $body $headers))

echo(ltpgtEmail sent successfullyltpgt)

else

echo(ltpgtMessage delivery failedltpgt)

gt

ASP NET 40 application error Unrecognized attribute ldquotargetFrameworkrdquo

If you find the following error when you attempt to open your web application

Description An error occurred during the processing of a configuration file required

to service this request Please review the specific error details below and modify your

configuration file appropriately

Parser Error Message Unrecognized attribute targetFramework Note that attribute

names are case-sensitive

The error indicates that your account is configured to run with the ASPNET 20

framework but your application is an ASPNET 40 application

To correct this simply login into MyAccount and under Windows Web IIS Admin

select 40 in the dropdown list named ldquoASPNET Versionrdquo as shown in the screen

below then click ldquoSet IIS propertiesrdquo

Install applications using Web Platform Installer

The Web Platform Installer provides easy installation of several popular web

applications to your web site This demonstration will show installation of a blog

system called Wordpress

Most applications requires a database If your product does not contain a database you

can contact Sales to get this If your database is not created you can do this from the

SQL section in MyAccount

The Web Platform Installer is a part of the IIS Manager for Remote

Administration tool

Web Platform Installer is a separate download from Microsoft The link to this is

located in MyAccount Windows Web Get Started

To start the Web Platform Installer open IIS Manager for Remote

Administration and go to Management section Double-click on the icon

The installer will use some seconds to load before starting

Choose either Whatrsquos new or Web Applications for browsing the applications

available for install

Web Applications has a several categories with types of applications

Click the information-icon to the right of application title to view more detailed

information about an application

This demonstration will install Wordpress from the Blogs section Click the Install

button when application has been chosen

A popup will list the application you have selected Click I Accept and the web

application will be downloaded

The next steps require information about your web site and database This information

can be found in MyAccount Passwords are sent to your domain names administrator

by e-mail

First enter a application name

To install the application on your web site root leave this box empty You will then

get a warning about the destination folder not being empty and you have to confirm to

overwrite existing files

Enter application name to install site in sub-folder Click Continue

The next and final step requires information about database passwords and other

important data

Important information

Some applications requires MSSQL and others MySQL database The Web

Platform Installer will show which database is required You need to go to the

correct product in MyAccount for information

In our example Wordpress requires MySQL

In the option Create a new or use an existing database it is important that you

choose Use existing database

Fill in information about database user password server location etc Click

Continue

If you get an error message about missing components (eg MySQL Connector for

Net) click the OK button

The site will be installed on web and database server and a confirmation page will be

displayed when completed

Click Launch to see site in browser and Finish to return to Web Platform Installer

If you want to install more than one application at once you can click more

checkboxes and then click Install The installation wizard will ask for information

required for each site chosen

How can I disable anonymous access to a folder and its subfolders in IIS75

It is possible to disable anonymous access to a specific folder and its subfolders To

do so simply create a webconfig file in that folder (or edit the existing one) with the

lines provided below It is required that Windows Authentication is enabled for

the site This must be done using the IIS 7 Manager ltxml version=10gt ltconfigurationgt ltsystemwebgt ltauthorizationgt ltdeny users= gt ltallow users=30030895Aexamplecomgt ltauthorizationgt ltsystemwebgt ltconfigurationgt

This way only the admin user specified would be able to access that folder and its

subfolders

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 3: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

How to connect with FTP over SSL using the FileZilla FTP client

Windows 2008 R2IIS 75 allows a secure FTP connection via FTP over SSL Note

that this is not the same as SFTP (FTP via SSH)

1 Click Open Site Manager

2 Click the New Site button and name the site

3 Fill in the following fields

a Logon type normal

b Host enter either your domain name or alternate FTP address

c Username ftpexamplecom|30030895Aexamplecom

d Password enter the password for this user

e Server type ldquoFTPES ndash FTP over explicit TLSSSLrdquo

4 Click Connect

Where did my IIS Manager settings go

There are two ways this could have happened

1) Yoursquove deleted the webconfig file

2) Yoursquove replaced the webconfig file with your own

The majority of the IIS Manager settings are stored in your individual webconfig file

This means that if you delete the webconfig file either by accident or on purpose

settings like anonymousbasic authentication default documents HTTP Errors etc

will be reset to the server default

You should also be aware that if you upload your own webconfig file you might

break your website by overwritingremoving features yoursquove set via the control panel

or IIS Remote Manager or you could end up trying to utilize features not allowed

under the current server configuration rendering the entire website unavailable

Log into IIS Manager for Remote Administration

The IIS Manager for Remote Administration is a tool from Microsoft which

provides administrators with the ability to securely manage IIS 75 web sites from a

remote computer

The IIS Manager can be downloaded from Microsoft The link can be found in

MyAccount

Log into MyAccount using your username and password In left menu go to

Windows Web and Get Started The link for IIS Manager and login details are

provided from the section IIS Manager for Remote Administration

The User Manager has an option for turning access to IIS Manager on or off Go to

Windows Web and User Manager to make sure it is on When the checkbox is

checked like image below the user has access to IIS Manager

After downloading and installing the tool it can be started from shortcut in Start-

menu The program will be called Internet Information Services (IIS) 7 Manager

Add a new connection to the site using the Connect to a Site function

Enter Server Name and Site name These settings can be found in MyAccount in Get

Started Click Next

Enter User name and Password These where sent to your domains administrator in

an e-mail Click Next

If the username or password is wrong you will get a warning about this after clicking

Next

The first time you add a new web site you might get this dialog box regarding

additional features which can be installed It is recommended to install all features

Check the box to the left of each feature and click OK The features will now be

installed

Finally enter a name for the web site connection We recommend using domain

name Click Finish

The site is now available for administration

How can I access WebDAV

WebDAV let you access your website over the https protocol as a network drive on

your local computer

First make sure your site and user account has been setup correctly in MyAccount

Control Panel

In MyAccount control panel (IIS Admin) make sure you have activated WebDAV

access for your site

In MyAccount control panel (User Manager) make sure you have activated WebDAV

access for your user

Now you are ready to access WebDAV from your Operating System If you are using

Windows you access WebDAV by clicking ldquoComputerrdquo in your Explorer window

and then choose ldquoMap network driverdquo

For security reasons we only allow WebDAV to be accessed using SSL so the https

protocol is required and you must use the ldquossl-encryptedcomrdquo shared SSL domain

we provide you in the MyAccount control panel (Get Started)

Select a drive letter you would like mapped to your site (ie Z)

As a ldquoFolderrdquo enter your ldquoWebDAV Hostnamerdquo found in MyAccount control

panel ie https[id]ssl-encryptedcom

Check ldquoConnect using different credentialsrdquo

Enter you Username and Password found in MyAccount control panel

You should now have Z connected to your site as a network drive

How to send email in ASPNET 20

Since version 20 ASPNET has a built in class (SystemNetMail) to send email See

the following code as example

C ASPNET

using SystemNetMail [hellip] MailMessage objEmail = new MailMessage( fromexamplecom toexamplecom This is the Subject This is the Body) objEmailPriority = MailPriorityNormal SmtpClient SMTPServer = new SmtpClient(localhost) try SMTPServerSend(objEmail) ResponseWrite(Email sent sucessfully) catch (Exception exc) ResponseWrite(Send failure + excToString())

VB ASPNET Imports SystemNetMail [hellip] Dim strFrom = fromexamplecom Dim strTo = toexamplecom Dim MailMsg As New MailMessage(New MailAddress(strFromTrim()) New MailAddress(strTo)) MailMsgSubject = This is the Subject MailMsgBody = This is the Body MailMsgPriority = MailPriorityNormal Dim SmtpMail As New SmtpClient SmtpMailHost = localhost Try SmtpMailSend(MailMsg) ResponseWrite(Email sent sucessfully) Catch exc As Exception ResponseWrite(excMessage) End Try

PHP ltphp

$to = toexamplecom

$subject = This is the subject

$body = This is the Body

$headers = From fromexamplecomrn

X-Mailer php

if (mail($to $subject $body $headers))

echo(ltpgtEmail sent successfullyltpgt)

else

echo(ltpgtMessage delivery failedltpgt)

gt

ASP NET 40 application error Unrecognized attribute ldquotargetFrameworkrdquo

If you find the following error when you attempt to open your web application

Description An error occurred during the processing of a configuration file required

to service this request Please review the specific error details below and modify your

configuration file appropriately

Parser Error Message Unrecognized attribute targetFramework Note that attribute

names are case-sensitive

The error indicates that your account is configured to run with the ASPNET 20

framework but your application is an ASPNET 40 application

To correct this simply login into MyAccount and under Windows Web IIS Admin

select 40 in the dropdown list named ldquoASPNET Versionrdquo as shown in the screen

below then click ldquoSet IIS propertiesrdquo

Install applications using Web Platform Installer

The Web Platform Installer provides easy installation of several popular web

applications to your web site This demonstration will show installation of a blog

system called Wordpress

Most applications requires a database If your product does not contain a database you

can contact Sales to get this If your database is not created you can do this from the

SQL section in MyAccount

The Web Platform Installer is a part of the IIS Manager for Remote

Administration tool

Web Platform Installer is a separate download from Microsoft The link to this is

located in MyAccount Windows Web Get Started

To start the Web Platform Installer open IIS Manager for Remote

Administration and go to Management section Double-click on the icon

The installer will use some seconds to load before starting

Choose either Whatrsquos new or Web Applications for browsing the applications

available for install

Web Applications has a several categories with types of applications

Click the information-icon to the right of application title to view more detailed

information about an application

This demonstration will install Wordpress from the Blogs section Click the Install

button when application has been chosen

A popup will list the application you have selected Click I Accept and the web

application will be downloaded

The next steps require information about your web site and database This information

can be found in MyAccount Passwords are sent to your domain names administrator

by e-mail

First enter a application name

To install the application on your web site root leave this box empty You will then

get a warning about the destination folder not being empty and you have to confirm to

overwrite existing files

Enter application name to install site in sub-folder Click Continue

The next and final step requires information about database passwords and other

important data

Important information

Some applications requires MSSQL and others MySQL database The Web

Platform Installer will show which database is required You need to go to the

correct product in MyAccount for information

In our example Wordpress requires MySQL

In the option Create a new or use an existing database it is important that you

choose Use existing database

Fill in information about database user password server location etc Click

Continue

If you get an error message about missing components (eg MySQL Connector for

Net) click the OK button

The site will be installed on web and database server and a confirmation page will be

displayed when completed

Click Launch to see site in browser and Finish to return to Web Platform Installer

If you want to install more than one application at once you can click more

checkboxes and then click Install The installation wizard will ask for information

required for each site chosen

How can I disable anonymous access to a folder and its subfolders in IIS75

It is possible to disable anonymous access to a specific folder and its subfolders To

do so simply create a webconfig file in that folder (or edit the existing one) with the

lines provided below It is required that Windows Authentication is enabled for

the site This must be done using the IIS 7 Manager ltxml version=10gt ltconfigurationgt ltsystemwebgt ltauthorizationgt ltdeny users= gt ltallow users=30030895Aexamplecomgt ltauthorizationgt ltsystemwebgt ltconfigurationgt

This way only the admin user specified would be able to access that folder and its

subfolders

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 4: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

Where did my IIS Manager settings go

There are two ways this could have happened

1) Yoursquove deleted the webconfig file

2) Yoursquove replaced the webconfig file with your own

The majority of the IIS Manager settings are stored in your individual webconfig file

This means that if you delete the webconfig file either by accident or on purpose

settings like anonymousbasic authentication default documents HTTP Errors etc

will be reset to the server default

You should also be aware that if you upload your own webconfig file you might

break your website by overwritingremoving features yoursquove set via the control panel

or IIS Remote Manager or you could end up trying to utilize features not allowed

under the current server configuration rendering the entire website unavailable

Log into IIS Manager for Remote Administration

The IIS Manager for Remote Administration is a tool from Microsoft which

provides administrators with the ability to securely manage IIS 75 web sites from a

remote computer

The IIS Manager can be downloaded from Microsoft The link can be found in

MyAccount

Log into MyAccount using your username and password In left menu go to

Windows Web and Get Started The link for IIS Manager and login details are

provided from the section IIS Manager for Remote Administration

The User Manager has an option for turning access to IIS Manager on or off Go to

Windows Web and User Manager to make sure it is on When the checkbox is

checked like image below the user has access to IIS Manager

After downloading and installing the tool it can be started from shortcut in Start-

menu The program will be called Internet Information Services (IIS) 7 Manager

Add a new connection to the site using the Connect to a Site function

Enter Server Name and Site name These settings can be found in MyAccount in Get

Started Click Next

Enter User name and Password These where sent to your domains administrator in

an e-mail Click Next

If the username or password is wrong you will get a warning about this after clicking

Next

The first time you add a new web site you might get this dialog box regarding

additional features which can be installed It is recommended to install all features

Check the box to the left of each feature and click OK The features will now be

installed

Finally enter a name for the web site connection We recommend using domain

name Click Finish

The site is now available for administration

How can I access WebDAV

WebDAV let you access your website over the https protocol as a network drive on

your local computer

First make sure your site and user account has been setup correctly in MyAccount

Control Panel

In MyAccount control panel (IIS Admin) make sure you have activated WebDAV

access for your site

In MyAccount control panel (User Manager) make sure you have activated WebDAV

access for your user

Now you are ready to access WebDAV from your Operating System If you are using

Windows you access WebDAV by clicking ldquoComputerrdquo in your Explorer window

and then choose ldquoMap network driverdquo

For security reasons we only allow WebDAV to be accessed using SSL so the https

protocol is required and you must use the ldquossl-encryptedcomrdquo shared SSL domain

we provide you in the MyAccount control panel (Get Started)

Select a drive letter you would like mapped to your site (ie Z)

As a ldquoFolderrdquo enter your ldquoWebDAV Hostnamerdquo found in MyAccount control

panel ie https[id]ssl-encryptedcom

Check ldquoConnect using different credentialsrdquo

Enter you Username and Password found in MyAccount control panel

You should now have Z connected to your site as a network drive

How to send email in ASPNET 20

Since version 20 ASPNET has a built in class (SystemNetMail) to send email See

the following code as example

C ASPNET

using SystemNetMail [hellip] MailMessage objEmail = new MailMessage( fromexamplecom toexamplecom This is the Subject This is the Body) objEmailPriority = MailPriorityNormal SmtpClient SMTPServer = new SmtpClient(localhost) try SMTPServerSend(objEmail) ResponseWrite(Email sent sucessfully) catch (Exception exc) ResponseWrite(Send failure + excToString())

VB ASPNET Imports SystemNetMail [hellip] Dim strFrom = fromexamplecom Dim strTo = toexamplecom Dim MailMsg As New MailMessage(New MailAddress(strFromTrim()) New MailAddress(strTo)) MailMsgSubject = This is the Subject MailMsgBody = This is the Body MailMsgPriority = MailPriorityNormal Dim SmtpMail As New SmtpClient SmtpMailHost = localhost Try SmtpMailSend(MailMsg) ResponseWrite(Email sent sucessfully) Catch exc As Exception ResponseWrite(excMessage) End Try

PHP ltphp

$to = toexamplecom

$subject = This is the subject

$body = This is the Body

$headers = From fromexamplecomrn

X-Mailer php

if (mail($to $subject $body $headers))

echo(ltpgtEmail sent successfullyltpgt)

else

echo(ltpgtMessage delivery failedltpgt)

gt

ASP NET 40 application error Unrecognized attribute ldquotargetFrameworkrdquo

If you find the following error when you attempt to open your web application

Description An error occurred during the processing of a configuration file required

to service this request Please review the specific error details below and modify your

configuration file appropriately

Parser Error Message Unrecognized attribute targetFramework Note that attribute

names are case-sensitive

The error indicates that your account is configured to run with the ASPNET 20

framework but your application is an ASPNET 40 application

To correct this simply login into MyAccount and under Windows Web IIS Admin

select 40 in the dropdown list named ldquoASPNET Versionrdquo as shown in the screen

below then click ldquoSet IIS propertiesrdquo

Install applications using Web Platform Installer

The Web Platform Installer provides easy installation of several popular web

applications to your web site This demonstration will show installation of a blog

system called Wordpress

Most applications requires a database If your product does not contain a database you

can contact Sales to get this If your database is not created you can do this from the

SQL section in MyAccount

The Web Platform Installer is a part of the IIS Manager for Remote

Administration tool

Web Platform Installer is a separate download from Microsoft The link to this is

located in MyAccount Windows Web Get Started

To start the Web Platform Installer open IIS Manager for Remote

Administration and go to Management section Double-click on the icon

The installer will use some seconds to load before starting

Choose either Whatrsquos new or Web Applications for browsing the applications

available for install

Web Applications has a several categories with types of applications

Click the information-icon to the right of application title to view more detailed

information about an application

This demonstration will install Wordpress from the Blogs section Click the Install

button when application has been chosen

A popup will list the application you have selected Click I Accept and the web

application will be downloaded

The next steps require information about your web site and database This information

can be found in MyAccount Passwords are sent to your domain names administrator

by e-mail

First enter a application name

To install the application on your web site root leave this box empty You will then

get a warning about the destination folder not being empty and you have to confirm to

overwrite existing files

Enter application name to install site in sub-folder Click Continue

The next and final step requires information about database passwords and other

important data

Important information

Some applications requires MSSQL and others MySQL database The Web

Platform Installer will show which database is required You need to go to the

correct product in MyAccount for information

In our example Wordpress requires MySQL

In the option Create a new or use an existing database it is important that you

choose Use existing database

Fill in information about database user password server location etc Click

Continue

If you get an error message about missing components (eg MySQL Connector for

Net) click the OK button

The site will be installed on web and database server and a confirmation page will be

displayed when completed

Click Launch to see site in browser and Finish to return to Web Platform Installer

If you want to install more than one application at once you can click more

checkboxes and then click Install The installation wizard will ask for information

required for each site chosen

How can I disable anonymous access to a folder and its subfolders in IIS75

It is possible to disable anonymous access to a specific folder and its subfolders To

do so simply create a webconfig file in that folder (or edit the existing one) with the

lines provided below It is required that Windows Authentication is enabled for

the site This must be done using the IIS 7 Manager ltxml version=10gt ltconfigurationgt ltsystemwebgt ltauthorizationgt ltdeny users= gt ltallow users=30030895Aexamplecomgt ltauthorizationgt ltsystemwebgt ltconfigurationgt

This way only the admin user specified would be able to access that folder and its

subfolders

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 5: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

Log into IIS Manager for Remote Administration

The IIS Manager for Remote Administration is a tool from Microsoft which

provides administrators with the ability to securely manage IIS 75 web sites from a

remote computer

The IIS Manager can be downloaded from Microsoft The link can be found in

MyAccount

Log into MyAccount using your username and password In left menu go to

Windows Web and Get Started The link for IIS Manager and login details are

provided from the section IIS Manager for Remote Administration

The User Manager has an option for turning access to IIS Manager on or off Go to

Windows Web and User Manager to make sure it is on When the checkbox is

checked like image below the user has access to IIS Manager

After downloading and installing the tool it can be started from shortcut in Start-

menu The program will be called Internet Information Services (IIS) 7 Manager

Add a new connection to the site using the Connect to a Site function

Enter Server Name and Site name These settings can be found in MyAccount in Get

Started Click Next

Enter User name and Password These where sent to your domains administrator in

an e-mail Click Next

If the username or password is wrong you will get a warning about this after clicking

Next

The first time you add a new web site you might get this dialog box regarding

additional features which can be installed It is recommended to install all features

Check the box to the left of each feature and click OK The features will now be

installed

Finally enter a name for the web site connection We recommend using domain

name Click Finish

The site is now available for administration

How can I access WebDAV

WebDAV let you access your website over the https protocol as a network drive on

your local computer

First make sure your site and user account has been setup correctly in MyAccount

Control Panel

In MyAccount control panel (IIS Admin) make sure you have activated WebDAV

access for your site

In MyAccount control panel (User Manager) make sure you have activated WebDAV

access for your user

Now you are ready to access WebDAV from your Operating System If you are using

Windows you access WebDAV by clicking ldquoComputerrdquo in your Explorer window

and then choose ldquoMap network driverdquo

For security reasons we only allow WebDAV to be accessed using SSL so the https

protocol is required and you must use the ldquossl-encryptedcomrdquo shared SSL domain

we provide you in the MyAccount control panel (Get Started)

Select a drive letter you would like mapped to your site (ie Z)

As a ldquoFolderrdquo enter your ldquoWebDAV Hostnamerdquo found in MyAccount control

panel ie https[id]ssl-encryptedcom

Check ldquoConnect using different credentialsrdquo

Enter you Username and Password found in MyAccount control panel

You should now have Z connected to your site as a network drive

How to send email in ASPNET 20

Since version 20 ASPNET has a built in class (SystemNetMail) to send email See

the following code as example

C ASPNET

using SystemNetMail [hellip] MailMessage objEmail = new MailMessage( fromexamplecom toexamplecom This is the Subject This is the Body) objEmailPriority = MailPriorityNormal SmtpClient SMTPServer = new SmtpClient(localhost) try SMTPServerSend(objEmail) ResponseWrite(Email sent sucessfully) catch (Exception exc) ResponseWrite(Send failure + excToString())

VB ASPNET Imports SystemNetMail [hellip] Dim strFrom = fromexamplecom Dim strTo = toexamplecom Dim MailMsg As New MailMessage(New MailAddress(strFromTrim()) New MailAddress(strTo)) MailMsgSubject = This is the Subject MailMsgBody = This is the Body MailMsgPriority = MailPriorityNormal Dim SmtpMail As New SmtpClient SmtpMailHost = localhost Try SmtpMailSend(MailMsg) ResponseWrite(Email sent sucessfully) Catch exc As Exception ResponseWrite(excMessage) End Try

PHP ltphp

$to = toexamplecom

$subject = This is the subject

$body = This is the Body

$headers = From fromexamplecomrn

X-Mailer php

if (mail($to $subject $body $headers))

echo(ltpgtEmail sent successfullyltpgt)

else

echo(ltpgtMessage delivery failedltpgt)

gt

ASP NET 40 application error Unrecognized attribute ldquotargetFrameworkrdquo

If you find the following error when you attempt to open your web application

Description An error occurred during the processing of a configuration file required

to service this request Please review the specific error details below and modify your

configuration file appropriately

Parser Error Message Unrecognized attribute targetFramework Note that attribute

names are case-sensitive

The error indicates that your account is configured to run with the ASPNET 20

framework but your application is an ASPNET 40 application

To correct this simply login into MyAccount and under Windows Web IIS Admin

select 40 in the dropdown list named ldquoASPNET Versionrdquo as shown in the screen

below then click ldquoSet IIS propertiesrdquo

Install applications using Web Platform Installer

The Web Platform Installer provides easy installation of several popular web

applications to your web site This demonstration will show installation of a blog

system called Wordpress

Most applications requires a database If your product does not contain a database you

can contact Sales to get this If your database is not created you can do this from the

SQL section in MyAccount

The Web Platform Installer is a part of the IIS Manager for Remote

Administration tool

Web Platform Installer is a separate download from Microsoft The link to this is

located in MyAccount Windows Web Get Started

To start the Web Platform Installer open IIS Manager for Remote

Administration and go to Management section Double-click on the icon

The installer will use some seconds to load before starting

Choose either Whatrsquos new or Web Applications for browsing the applications

available for install

Web Applications has a several categories with types of applications

Click the information-icon to the right of application title to view more detailed

information about an application

This demonstration will install Wordpress from the Blogs section Click the Install

button when application has been chosen

A popup will list the application you have selected Click I Accept and the web

application will be downloaded

The next steps require information about your web site and database This information

can be found in MyAccount Passwords are sent to your domain names administrator

by e-mail

First enter a application name

To install the application on your web site root leave this box empty You will then

get a warning about the destination folder not being empty and you have to confirm to

overwrite existing files

Enter application name to install site in sub-folder Click Continue

The next and final step requires information about database passwords and other

important data

Important information

Some applications requires MSSQL and others MySQL database The Web

Platform Installer will show which database is required You need to go to the

correct product in MyAccount for information

In our example Wordpress requires MySQL

In the option Create a new or use an existing database it is important that you

choose Use existing database

Fill in information about database user password server location etc Click

Continue

If you get an error message about missing components (eg MySQL Connector for

Net) click the OK button

The site will be installed on web and database server and a confirmation page will be

displayed when completed

Click Launch to see site in browser and Finish to return to Web Platform Installer

If you want to install more than one application at once you can click more

checkboxes and then click Install The installation wizard will ask for information

required for each site chosen

How can I disable anonymous access to a folder and its subfolders in IIS75

It is possible to disable anonymous access to a specific folder and its subfolders To

do so simply create a webconfig file in that folder (or edit the existing one) with the

lines provided below It is required that Windows Authentication is enabled for

the site This must be done using the IIS 7 Manager ltxml version=10gt ltconfigurationgt ltsystemwebgt ltauthorizationgt ltdeny users= gt ltallow users=30030895Aexamplecomgt ltauthorizationgt ltsystemwebgt ltconfigurationgt

This way only the admin user specified would be able to access that folder and its

subfolders

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 6: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

Enter Server Name and Site name These settings can be found in MyAccount in Get

Started Click Next

Enter User name and Password These where sent to your domains administrator in

an e-mail Click Next

If the username or password is wrong you will get a warning about this after clicking

Next

The first time you add a new web site you might get this dialog box regarding

additional features which can be installed It is recommended to install all features

Check the box to the left of each feature and click OK The features will now be

installed

Finally enter a name for the web site connection We recommend using domain

name Click Finish

The site is now available for administration

How can I access WebDAV

WebDAV let you access your website over the https protocol as a network drive on

your local computer

First make sure your site and user account has been setup correctly in MyAccount

Control Panel

In MyAccount control panel (IIS Admin) make sure you have activated WebDAV

access for your site

In MyAccount control panel (User Manager) make sure you have activated WebDAV

access for your user

Now you are ready to access WebDAV from your Operating System If you are using

Windows you access WebDAV by clicking ldquoComputerrdquo in your Explorer window

and then choose ldquoMap network driverdquo

For security reasons we only allow WebDAV to be accessed using SSL so the https

protocol is required and you must use the ldquossl-encryptedcomrdquo shared SSL domain

we provide you in the MyAccount control panel (Get Started)

Select a drive letter you would like mapped to your site (ie Z)

As a ldquoFolderrdquo enter your ldquoWebDAV Hostnamerdquo found in MyAccount control

panel ie https[id]ssl-encryptedcom

Check ldquoConnect using different credentialsrdquo

Enter you Username and Password found in MyAccount control panel

You should now have Z connected to your site as a network drive

How to send email in ASPNET 20

Since version 20 ASPNET has a built in class (SystemNetMail) to send email See

the following code as example

C ASPNET

using SystemNetMail [hellip] MailMessage objEmail = new MailMessage( fromexamplecom toexamplecom This is the Subject This is the Body) objEmailPriority = MailPriorityNormal SmtpClient SMTPServer = new SmtpClient(localhost) try SMTPServerSend(objEmail) ResponseWrite(Email sent sucessfully) catch (Exception exc) ResponseWrite(Send failure + excToString())

VB ASPNET Imports SystemNetMail [hellip] Dim strFrom = fromexamplecom Dim strTo = toexamplecom Dim MailMsg As New MailMessage(New MailAddress(strFromTrim()) New MailAddress(strTo)) MailMsgSubject = This is the Subject MailMsgBody = This is the Body MailMsgPriority = MailPriorityNormal Dim SmtpMail As New SmtpClient SmtpMailHost = localhost Try SmtpMailSend(MailMsg) ResponseWrite(Email sent sucessfully) Catch exc As Exception ResponseWrite(excMessage) End Try

PHP ltphp

$to = toexamplecom

$subject = This is the subject

$body = This is the Body

$headers = From fromexamplecomrn

X-Mailer php

if (mail($to $subject $body $headers))

echo(ltpgtEmail sent successfullyltpgt)

else

echo(ltpgtMessage delivery failedltpgt)

gt

ASP NET 40 application error Unrecognized attribute ldquotargetFrameworkrdquo

If you find the following error when you attempt to open your web application

Description An error occurred during the processing of a configuration file required

to service this request Please review the specific error details below and modify your

configuration file appropriately

Parser Error Message Unrecognized attribute targetFramework Note that attribute

names are case-sensitive

The error indicates that your account is configured to run with the ASPNET 20

framework but your application is an ASPNET 40 application

To correct this simply login into MyAccount and under Windows Web IIS Admin

select 40 in the dropdown list named ldquoASPNET Versionrdquo as shown in the screen

below then click ldquoSet IIS propertiesrdquo

Install applications using Web Platform Installer

The Web Platform Installer provides easy installation of several popular web

applications to your web site This demonstration will show installation of a blog

system called Wordpress

Most applications requires a database If your product does not contain a database you

can contact Sales to get this If your database is not created you can do this from the

SQL section in MyAccount

The Web Platform Installer is a part of the IIS Manager for Remote

Administration tool

Web Platform Installer is a separate download from Microsoft The link to this is

located in MyAccount Windows Web Get Started

To start the Web Platform Installer open IIS Manager for Remote

Administration and go to Management section Double-click on the icon

The installer will use some seconds to load before starting

Choose either Whatrsquos new or Web Applications for browsing the applications

available for install

Web Applications has a several categories with types of applications

Click the information-icon to the right of application title to view more detailed

information about an application

This demonstration will install Wordpress from the Blogs section Click the Install

button when application has been chosen

A popup will list the application you have selected Click I Accept and the web

application will be downloaded

The next steps require information about your web site and database This information

can be found in MyAccount Passwords are sent to your domain names administrator

by e-mail

First enter a application name

To install the application on your web site root leave this box empty You will then

get a warning about the destination folder not being empty and you have to confirm to

overwrite existing files

Enter application name to install site in sub-folder Click Continue

The next and final step requires information about database passwords and other

important data

Important information

Some applications requires MSSQL and others MySQL database The Web

Platform Installer will show which database is required You need to go to the

correct product in MyAccount for information

In our example Wordpress requires MySQL

In the option Create a new or use an existing database it is important that you

choose Use existing database

Fill in information about database user password server location etc Click

Continue

If you get an error message about missing components (eg MySQL Connector for

Net) click the OK button

The site will be installed on web and database server and a confirmation page will be

displayed when completed

Click Launch to see site in browser and Finish to return to Web Platform Installer

If you want to install more than one application at once you can click more

checkboxes and then click Install The installation wizard will ask for information

required for each site chosen

How can I disable anonymous access to a folder and its subfolders in IIS75

It is possible to disable anonymous access to a specific folder and its subfolders To

do so simply create a webconfig file in that folder (or edit the existing one) with the

lines provided below It is required that Windows Authentication is enabled for

the site This must be done using the IIS 7 Manager ltxml version=10gt ltconfigurationgt ltsystemwebgt ltauthorizationgt ltdeny users= gt ltallow users=30030895Aexamplecomgt ltauthorizationgt ltsystemwebgt ltconfigurationgt

This way only the admin user specified would be able to access that folder and its

subfolders

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 7: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

The first time you add a new web site you might get this dialog box regarding

additional features which can be installed It is recommended to install all features

Check the box to the left of each feature and click OK The features will now be

installed

Finally enter a name for the web site connection We recommend using domain

name Click Finish

The site is now available for administration

How can I access WebDAV

WebDAV let you access your website over the https protocol as a network drive on

your local computer

First make sure your site and user account has been setup correctly in MyAccount

Control Panel

In MyAccount control panel (IIS Admin) make sure you have activated WebDAV

access for your site

In MyAccount control panel (User Manager) make sure you have activated WebDAV

access for your user

Now you are ready to access WebDAV from your Operating System If you are using

Windows you access WebDAV by clicking ldquoComputerrdquo in your Explorer window

and then choose ldquoMap network driverdquo

For security reasons we only allow WebDAV to be accessed using SSL so the https

protocol is required and you must use the ldquossl-encryptedcomrdquo shared SSL domain

we provide you in the MyAccount control panel (Get Started)

Select a drive letter you would like mapped to your site (ie Z)

As a ldquoFolderrdquo enter your ldquoWebDAV Hostnamerdquo found in MyAccount control

panel ie https[id]ssl-encryptedcom

Check ldquoConnect using different credentialsrdquo

Enter you Username and Password found in MyAccount control panel

You should now have Z connected to your site as a network drive

How to send email in ASPNET 20

Since version 20 ASPNET has a built in class (SystemNetMail) to send email See

the following code as example

C ASPNET

using SystemNetMail [hellip] MailMessage objEmail = new MailMessage( fromexamplecom toexamplecom This is the Subject This is the Body) objEmailPriority = MailPriorityNormal SmtpClient SMTPServer = new SmtpClient(localhost) try SMTPServerSend(objEmail) ResponseWrite(Email sent sucessfully) catch (Exception exc) ResponseWrite(Send failure + excToString())

VB ASPNET Imports SystemNetMail [hellip] Dim strFrom = fromexamplecom Dim strTo = toexamplecom Dim MailMsg As New MailMessage(New MailAddress(strFromTrim()) New MailAddress(strTo)) MailMsgSubject = This is the Subject MailMsgBody = This is the Body MailMsgPriority = MailPriorityNormal Dim SmtpMail As New SmtpClient SmtpMailHost = localhost Try SmtpMailSend(MailMsg) ResponseWrite(Email sent sucessfully) Catch exc As Exception ResponseWrite(excMessage) End Try

PHP ltphp

$to = toexamplecom

$subject = This is the subject

$body = This is the Body

$headers = From fromexamplecomrn

X-Mailer php

if (mail($to $subject $body $headers))

echo(ltpgtEmail sent successfullyltpgt)

else

echo(ltpgtMessage delivery failedltpgt)

gt

ASP NET 40 application error Unrecognized attribute ldquotargetFrameworkrdquo

If you find the following error when you attempt to open your web application

Description An error occurred during the processing of a configuration file required

to service this request Please review the specific error details below and modify your

configuration file appropriately

Parser Error Message Unrecognized attribute targetFramework Note that attribute

names are case-sensitive

The error indicates that your account is configured to run with the ASPNET 20

framework but your application is an ASPNET 40 application

To correct this simply login into MyAccount and under Windows Web IIS Admin

select 40 in the dropdown list named ldquoASPNET Versionrdquo as shown in the screen

below then click ldquoSet IIS propertiesrdquo

Install applications using Web Platform Installer

The Web Platform Installer provides easy installation of several popular web

applications to your web site This demonstration will show installation of a blog

system called Wordpress

Most applications requires a database If your product does not contain a database you

can contact Sales to get this If your database is not created you can do this from the

SQL section in MyAccount

The Web Platform Installer is a part of the IIS Manager for Remote

Administration tool

Web Platform Installer is a separate download from Microsoft The link to this is

located in MyAccount Windows Web Get Started

To start the Web Platform Installer open IIS Manager for Remote

Administration and go to Management section Double-click on the icon

The installer will use some seconds to load before starting

Choose either Whatrsquos new or Web Applications for browsing the applications

available for install

Web Applications has a several categories with types of applications

Click the information-icon to the right of application title to view more detailed

information about an application

This demonstration will install Wordpress from the Blogs section Click the Install

button when application has been chosen

A popup will list the application you have selected Click I Accept and the web

application will be downloaded

The next steps require information about your web site and database This information

can be found in MyAccount Passwords are sent to your domain names administrator

by e-mail

First enter a application name

To install the application on your web site root leave this box empty You will then

get a warning about the destination folder not being empty and you have to confirm to

overwrite existing files

Enter application name to install site in sub-folder Click Continue

The next and final step requires information about database passwords and other

important data

Important information

Some applications requires MSSQL and others MySQL database The Web

Platform Installer will show which database is required You need to go to the

correct product in MyAccount for information

In our example Wordpress requires MySQL

In the option Create a new or use an existing database it is important that you

choose Use existing database

Fill in information about database user password server location etc Click

Continue

If you get an error message about missing components (eg MySQL Connector for

Net) click the OK button

The site will be installed on web and database server and a confirmation page will be

displayed when completed

Click Launch to see site in browser and Finish to return to Web Platform Installer

If you want to install more than one application at once you can click more

checkboxes and then click Install The installation wizard will ask for information

required for each site chosen

How can I disable anonymous access to a folder and its subfolders in IIS75

It is possible to disable anonymous access to a specific folder and its subfolders To

do so simply create a webconfig file in that folder (or edit the existing one) with the

lines provided below It is required that Windows Authentication is enabled for

the site This must be done using the IIS 7 Manager ltxml version=10gt ltconfigurationgt ltsystemwebgt ltauthorizationgt ltdeny users= gt ltallow users=30030895Aexamplecomgt ltauthorizationgt ltsystemwebgt ltconfigurationgt

This way only the admin user specified would be able to access that folder and its

subfolders

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 8: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

The site is now available for administration

How can I access WebDAV

WebDAV let you access your website over the https protocol as a network drive on

your local computer

First make sure your site and user account has been setup correctly in MyAccount

Control Panel

In MyAccount control panel (IIS Admin) make sure you have activated WebDAV

access for your site

In MyAccount control panel (User Manager) make sure you have activated WebDAV

access for your user

Now you are ready to access WebDAV from your Operating System If you are using

Windows you access WebDAV by clicking ldquoComputerrdquo in your Explorer window

and then choose ldquoMap network driverdquo

For security reasons we only allow WebDAV to be accessed using SSL so the https

protocol is required and you must use the ldquossl-encryptedcomrdquo shared SSL domain

we provide you in the MyAccount control panel (Get Started)

Select a drive letter you would like mapped to your site (ie Z)

As a ldquoFolderrdquo enter your ldquoWebDAV Hostnamerdquo found in MyAccount control

panel ie https[id]ssl-encryptedcom

Check ldquoConnect using different credentialsrdquo

Enter you Username and Password found in MyAccount control panel

You should now have Z connected to your site as a network drive

How to send email in ASPNET 20

Since version 20 ASPNET has a built in class (SystemNetMail) to send email See

the following code as example

C ASPNET

using SystemNetMail [hellip] MailMessage objEmail = new MailMessage( fromexamplecom toexamplecom This is the Subject This is the Body) objEmailPriority = MailPriorityNormal SmtpClient SMTPServer = new SmtpClient(localhost) try SMTPServerSend(objEmail) ResponseWrite(Email sent sucessfully) catch (Exception exc) ResponseWrite(Send failure + excToString())

VB ASPNET Imports SystemNetMail [hellip] Dim strFrom = fromexamplecom Dim strTo = toexamplecom Dim MailMsg As New MailMessage(New MailAddress(strFromTrim()) New MailAddress(strTo)) MailMsgSubject = This is the Subject MailMsgBody = This is the Body MailMsgPriority = MailPriorityNormal Dim SmtpMail As New SmtpClient SmtpMailHost = localhost Try SmtpMailSend(MailMsg) ResponseWrite(Email sent sucessfully) Catch exc As Exception ResponseWrite(excMessage) End Try

PHP ltphp

$to = toexamplecom

$subject = This is the subject

$body = This is the Body

$headers = From fromexamplecomrn

X-Mailer php

if (mail($to $subject $body $headers))

echo(ltpgtEmail sent successfullyltpgt)

else

echo(ltpgtMessage delivery failedltpgt)

gt

ASP NET 40 application error Unrecognized attribute ldquotargetFrameworkrdquo

If you find the following error when you attempt to open your web application

Description An error occurred during the processing of a configuration file required

to service this request Please review the specific error details below and modify your

configuration file appropriately

Parser Error Message Unrecognized attribute targetFramework Note that attribute

names are case-sensitive

The error indicates that your account is configured to run with the ASPNET 20

framework but your application is an ASPNET 40 application

To correct this simply login into MyAccount and under Windows Web IIS Admin

select 40 in the dropdown list named ldquoASPNET Versionrdquo as shown in the screen

below then click ldquoSet IIS propertiesrdquo

Install applications using Web Platform Installer

The Web Platform Installer provides easy installation of several popular web

applications to your web site This demonstration will show installation of a blog

system called Wordpress

Most applications requires a database If your product does not contain a database you

can contact Sales to get this If your database is not created you can do this from the

SQL section in MyAccount

The Web Platform Installer is a part of the IIS Manager for Remote

Administration tool

Web Platform Installer is a separate download from Microsoft The link to this is

located in MyAccount Windows Web Get Started

To start the Web Platform Installer open IIS Manager for Remote

Administration and go to Management section Double-click on the icon

The installer will use some seconds to load before starting

Choose either Whatrsquos new or Web Applications for browsing the applications

available for install

Web Applications has a several categories with types of applications

Click the information-icon to the right of application title to view more detailed

information about an application

This demonstration will install Wordpress from the Blogs section Click the Install

button when application has been chosen

A popup will list the application you have selected Click I Accept and the web

application will be downloaded

The next steps require information about your web site and database This information

can be found in MyAccount Passwords are sent to your domain names administrator

by e-mail

First enter a application name

To install the application on your web site root leave this box empty You will then

get a warning about the destination folder not being empty and you have to confirm to

overwrite existing files

Enter application name to install site in sub-folder Click Continue

The next and final step requires information about database passwords and other

important data

Important information

Some applications requires MSSQL and others MySQL database The Web

Platform Installer will show which database is required You need to go to the

correct product in MyAccount for information

In our example Wordpress requires MySQL

In the option Create a new or use an existing database it is important that you

choose Use existing database

Fill in information about database user password server location etc Click

Continue

If you get an error message about missing components (eg MySQL Connector for

Net) click the OK button

The site will be installed on web and database server and a confirmation page will be

displayed when completed

Click Launch to see site in browser and Finish to return to Web Platform Installer

If you want to install more than one application at once you can click more

checkboxes and then click Install The installation wizard will ask for information

required for each site chosen

How can I disable anonymous access to a folder and its subfolders in IIS75

It is possible to disable anonymous access to a specific folder and its subfolders To

do so simply create a webconfig file in that folder (or edit the existing one) with the

lines provided below It is required that Windows Authentication is enabled for

the site This must be done using the IIS 7 Manager ltxml version=10gt ltconfigurationgt ltsystemwebgt ltauthorizationgt ltdeny users= gt ltallow users=30030895Aexamplecomgt ltauthorizationgt ltsystemwebgt ltconfigurationgt

This way only the admin user specified would be able to access that folder and its

subfolders

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 9: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

How can I access WebDAV

WebDAV let you access your website over the https protocol as a network drive on

your local computer

First make sure your site and user account has been setup correctly in MyAccount

Control Panel

In MyAccount control panel (IIS Admin) make sure you have activated WebDAV

access for your site

In MyAccount control panel (User Manager) make sure you have activated WebDAV

access for your user

Now you are ready to access WebDAV from your Operating System If you are using

Windows you access WebDAV by clicking ldquoComputerrdquo in your Explorer window

and then choose ldquoMap network driverdquo

For security reasons we only allow WebDAV to be accessed using SSL so the https

protocol is required and you must use the ldquossl-encryptedcomrdquo shared SSL domain

we provide you in the MyAccount control panel (Get Started)

Select a drive letter you would like mapped to your site (ie Z)

As a ldquoFolderrdquo enter your ldquoWebDAV Hostnamerdquo found in MyAccount control

panel ie https[id]ssl-encryptedcom

Check ldquoConnect using different credentialsrdquo

Enter you Username and Password found in MyAccount control panel

You should now have Z connected to your site as a network drive

How to send email in ASPNET 20

Since version 20 ASPNET has a built in class (SystemNetMail) to send email See

the following code as example

C ASPNET

using SystemNetMail [hellip] MailMessage objEmail = new MailMessage( fromexamplecom toexamplecom This is the Subject This is the Body) objEmailPriority = MailPriorityNormal SmtpClient SMTPServer = new SmtpClient(localhost) try SMTPServerSend(objEmail) ResponseWrite(Email sent sucessfully) catch (Exception exc) ResponseWrite(Send failure + excToString())

VB ASPNET Imports SystemNetMail [hellip] Dim strFrom = fromexamplecom Dim strTo = toexamplecom Dim MailMsg As New MailMessage(New MailAddress(strFromTrim()) New MailAddress(strTo)) MailMsgSubject = This is the Subject MailMsgBody = This is the Body MailMsgPriority = MailPriorityNormal Dim SmtpMail As New SmtpClient SmtpMailHost = localhost Try SmtpMailSend(MailMsg) ResponseWrite(Email sent sucessfully) Catch exc As Exception ResponseWrite(excMessage) End Try

PHP ltphp

$to = toexamplecom

$subject = This is the subject

$body = This is the Body

$headers = From fromexamplecomrn

X-Mailer php

if (mail($to $subject $body $headers))

echo(ltpgtEmail sent successfullyltpgt)

else

echo(ltpgtMessage delivery failedltpgt)

gt

ASP NET 40 application error Unrecognized attribute ldquotargetFrameworkrdquo

If you find the following error when you attempt to open your web application

Description An error occurred during the processing of a configuration file required

to service this request Please review the specific error details below and modify your

configuration file appropriately

Parser Error Message Unrecognized attribute targetFramework Note that attribute

names are case-sensitive

The error indicates that your account is configured to run with the ASPNET 20

framework but your application is an ASPNET 40 application

To correct this simply login into MyAccount and under Windows Web IIS Admin

select 40 in the dropdown list named ldquoASPNET Versionrdquo as shown in the screen

below then click ldquoSet IIS propertiesrdquo

Install applications using Web Platform Installer

The Web Platform Installer provides easy installation of several popular web

applications to your web site This demonstration will show installation of a blog

system called Wordpress

Most applications requires a database If your product does not contain a database you

can contact Sales to get this If your database is not created you can do this from the

SQL section in MyAccount

The Web Platform Installer is a part of the IIS Manager for Remote

Administration tool

Web Platform Installer is a separate download from Microsoft The link to this is

located in MyAccount Windows Web Get Started

To start the Web Platform Installer open IIS Manager for Remote

Administration and go to Management section Double-click on the icon

The installer will use some seconds to load before starting

Choose either Whatrsquos new or Web Applications for browsing the applications

available for install

Web Applications has a several categories with types of applications

Click the information-icon to the right of application title to view more detailed

information about an application

This demonstration will install Wordpress from the Blogs section Click the Install

button when application has been chosen

A popup will list the application you have selected Click I Accept and the web

application will be downloaded

The next steps require information about your web site and database This information

can be found in MyAccount Passwords are sent to your domain names administrator

by e-mail

First enter a application name

To install the application on your web site root leave this box empty You will then

get a warning about the destination folder not being empty and you have to confirm to

overwrite existing files

Enter application name to install site in sub-folder Click Continue

The next and final step requires information about database passwords and other

important data

Important information

Some applications requires MSSQL and others MySQL database The Web

Platform Installer will show which database is required You need to go to the

correct product in MyAccount for information

In our example Wordpress requires MySQL

In the option Create a new or use an existing database it is important that you

choose Use existing database

Fill in information about database user password server location etc Click

Continue

If you get an error message about missing components (eg MySQL Connector for

Net) click the OK button

The site will be installed on web and database server and a confirmation page will be

displayed when completed

Click Launch to see site in browser and Finish to return to Web Platform Installer

If you want to install more than one application at once you can click more

checkboxes and then click Install The installation wizard will ask for information

required for each site chosen

How can I disable anonymous access to a folder and its subfolders in IIS75

It is possible to disable anonymous access to a specific folder and its subfolders To

do so simply create a webconfig file in that folder (or edit the existing one) with the

lines provided below It is required that Windows Authentication is enabled for

the site This must be done using the IIS 7 Manager ltxml version=10gt ltconfigurationgt ltsystemwebgt ltauthorizationgt ltdeny users= gt ltallow users=30030895Aexamplecomgt ltauthorizationgt ltsystemwebgt ltconfigurationgt

This way only the admin user specified would be able to access that folder and its

subfolders

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 10: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

For security reasons we only allow WebDAV to be accessed using SSL so the https

protocol is required and you must use the ldquossl-encryptedcomrdquo shared SSL domain

we provide you in the MyAccount control panel (Get Started)

Select a drive letter you would like mapped to your site (ie Z)

As a ldquoFolderrdquo enter your ldquoWebDAV Hostnamerdquo found in MyAccount control

panel ie https[id]ssl-encryptedcom

Check ldquoConnect using different credentialsrdquo

Enter you Username and Password found in MyAccount control panel

You should now have Z connected to your site as a network drive

How to send email in ASPNET 20

Since version 20 ASPNET has a built in class (SystemNetMail) to send email See

the following code as example

C ASPNET

using SystemNetMail [hellip] MailMessage objEmail = new MailMessage( fromexamplecom toexamplecom This is the Subject This is the Body) objEmailPriority = MailPriorityNormal SmtpClient SMTPServer = new SmtpClient(localhost) try SMTPServerSend(objEmail) ResponseWrite(Email sent sucessfully) catch (Exception exc) ResponseWrite(Send failure + excToString())

VB ASPNET Imports SystemNetMail [hellip] Dim strFrom = fromexamplecom Dim strTo = toexamplecom Dim MailMsg As New MailMessage(New MailAddress(strFromTrim()) New MailAddress(strTo)) MailMsgSubject = This is the Subject MailMsgBody = This is the Body MailMsgPriority = MailPriorityNormal Dim SmtpMail As New SmtpClient SmtpMailHost = localhost Try SmtpMailSend(MailMsg) ResponseWrite(Email sent sucessfully) Catch exc As Exception ResponseWrite(excMessage) End Try

PHP ltphp

$to = toexamplecom

$subject = This is the subject

$body = This is the Body

$headers = From fromexamplecomrn

X-Mailer php

if (mail($to $subject $body $headers))

echo(ltpgtEmail sent successfullyltpgt)

else

echo(ltpgtMessage delivery failedltpgt)

gt

ASP NET 40 application error Unrecognized attribute ldquotargetFrameworkrdquo

If you find the following error when you attempt to open your web application

Description An error occurred during the processing of a configuration file required

to service this request Please review the specific error details below and modify your

configuration file appropriately

Parser Error Message Unrecognized attribute targetFramework Note that attribute

names are case-sensitive

The error indicates that your account is configured to run with the ASPNET 20

framework but your application is an ASPNET 40 application

To correct this simply login into MyAccount and under Windows Web IIS Admin

select 40 in the dropdown list named ldquoASPNET Versionrdquo as shown in the screen

below then click ldquoSet IIS propertiesrdquo

Install applications using Web Platform Installer

The Web Platform Installer provides easy installation of several popular web

applications to your web site This demonstration will show installation of a blog

system called Wordpress

Most applications requires a database If your product does not contain a database you

can contact Sales to get this If your database is not created you can do this from the

SQL section in MyAccount

The Web Platform Installer is a part of the IIS Manager for Remote

Administration tool

Web Platform Installer is a separate download from Microsoft The link to this is

located in MyAccount Windows Web Get Started

To start the Web Platform Installer open IIS Manager for Remote

Administration and go to Management section Double-click on the icon

The installer will use some seconds to load before starting

Choose either Whatrsquos new or Web Applications for browsing the applications

available for install

Web Applications has a several categories with types of applications

Click the information-icon to the right of application title to view more detailed

information about an application

This demonstration will install Wordpress from the Blogs section Click the Install

button when application has been chosen

A popup will list the application you have selected Click I Accept and the web

application will be downloaded

The next steps require information about your web site and database This information

can be found in MyAccount Passwords are sent to your domain names administrator

by e-mail

First enter a application name

To install the application on your web site root leave this box empty You will then

get a warning about the destination folder not being empty and you have to confirm to

overwrite existing files

Enter application name to install site in sub-folder Click Continue

The next and final step requires information about database passwords and other

important data

Important information

Some applications requires MSSQL and others MySQL database The Web

Platform Installer will show which database is required You need to go to the

correct product in MyAccount for information

In our example Wordpress requires MySQL

In the option Create a new or use an existing database it is important that you

choose Use existing database

Fill in information about database user password server location etc Click

Continue

If you get an error message about missing components (eg MySQL Connector for

Net) click the OK button

The site will be installed on web and database server and a confirmation page will be

displayed when completed

Click Launch to see site in browser and Finish to return to Web Platform Installer

If you want to install more than one application at once you can click more

checkboxes and then click Install The installation wizard will ask for information

required for each site chosen

How can I disable anonymous access to a folder and its subfolders in IIS75

It is possible to disable anonymous access to a specific folder and its subfolders To

do so simply create a webconfig file in that folder (or edit the existing one) with the

lines provided below It is required that Windows Authentication is enabled for

the site This must be done using the IIS 7 Manager ltxml version=10gt ltconfigurationgt ltsystemwebgt ltauthorizationgt ltdeny users= gt ltallow users=30030895Aexamplecomgt ltauthorizationgt ltsystemwebgt ltconfigurationgt

This way only the admin user specified would be able to access that folder and its

subfolders

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 11: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

Check ldquoConnect using different credentialsrdquo

Enter you Username and Password found in MyAccount control panel

You should now have Z connected to your site as a network drive

How to send email in ASPNET 20

Since version 20 ASPNET has a built in class (SystemNetMail) to send email See

the following code as example

C ASPNET

using SystemNetMail [hellip] MailMessage objEmail = new MailMessage( fromexamplecom toexamplecom This is the Subject This is the Body) objEmailPriority = MailPriorityNormal SmtpClient SMTPServer = new SmtpClient(localhost) try SMTPServerSend(objEmail) ResponseWrite(Email sent sucessfully) catch (Exception exc) ResponseWrite(Send failure + excToString())

VB ASPNET Imports SystemNetMail [hellip] Dim strFrom = fromexamplecom Dim strTo = toexamplecom Dim MailMsg As New MailMessage(New MailAddress(strFromTrim()) New MailAddress(strTo)) MailMsgSubject = This is the Subject MailMsgBody = This is the Body MailMsgPriority = MailPriorityNormal Dim SmtpMail As New SmtpClient SmtpMailHost = localhost Try SmtpMailSend(MailMsg) ResponseWrite(Email sent sucessfully) Catch exc As Exception ResponseWrite(excMessage) End Try

PHP ltphp

$to = toexamplecom

$subject = This is the subject

$body = This is the Body

$headers = From fromexamplecomrn

X-Mailer php

if (mail($to $subject $body $headers))

echo(ltpgtEmail sent successfullyltpgt)

else

echo(ltpgtMessage delivery failedltpgt)

gt

ASP NET 40 application error Unrecognized attribute ldquotargetFrameworkrdquo

If you find the following error when you attempt to open your web application

Description An error occurred during the processing of a configuration file required

to service this request Please review the specific error details below and modify your

configuration file appropriately

Parser Error Message Unrecognized attribute targetFramework Note that attribute

names are case-sensitive

The error indicates that your account is configured to run with the ASPNET 20

framework but your application is an ASPNET 40 application

To correct this simply login into MyAccount and under Windows Web IIS Admin

select 40 in the dropdown list named ldquoASPNET Versionrdquo as shown in the screen

below then click ldquoSet IIS propertiesrdquo

Install applications using Web Platform Installer

The Web Platform Installer provides easy installation of several popular web

applications to your web site This demonstration will show installation of a blog

system called Wordpress

Most applications requires a database If your product does not contain a database you

can contact Sales to get this If your database is not created you can do this from the

SQL section in MyAccount

The Web Platform Installer is a part of the IIS Manager for Remote

Administration tool

Web Platform Installer is a separate download from Microsoft The link to this is

located in MyAccount Windows Web Get Started

To start the Web Platform Installer open IIS Manager for Remote

Administration and go to Management section Double-click on the icon

The installer will use some seconds to load before starting

Choose either Whatrsquos new or Web Applications for browsing the applications

available for install

Web Applications has a several categories with types of applications

Click the information-icon to the right of application title to view more detailed

information about an application

This demonstration will install Wordpress from the Blogs section Click the Install

button when application has been chosen

A popup will list the application you have selected Click I Accept and the web

application will be downloaded

The next steps require information about your web site and database This information

can be found in MyAccount Passwords are sent to your domain names administrator

by e-mail

First enter a application name

To install the application on your web site root leave this box empty You will then

get a warning about the destination folder not being empty and you have to confirm to

overwrite existing files

Enter application name to install site in sub-folder Click Continue

The next and final step requires information about database passwords and other

important data

Important information

Some applications requires MSSQL and others MySQL database The Web

Platform Installer will show which database is required You need to go to the

correct product in MyAccount for information

In our example Wordpress requires MySQL

In the option Create a new or use an existing database it is important that you

choose Use existing database

Fill in information about database user password server location etc Click

Continue

If you get an error message about missing components (eg MySQL Connector for

Net) click the OK button

The site will be installed on web and database server and a confirmation page will be

displayed when completed

Click Launch to see site in browser and Finish to return to Web Platform Installer

If you want to install more than one application at once you can click more

checkboxes and then click Install The installation wizard will ask for information

required for each site chosen

How can I disable anonymous access to a folder and its subfolders in IIS75

It is possible to disable anonymous access to a specific folder and its subfolders To

do so simply create a webconfig file in that folder (or edit the existing one) with the

lines provided below It is required that Windows Authentication is enabled for

the site This must be done using the IIS 7 Manager ltxml version=10gt ltconfigurationgt ltsystemwebgt ltauthorizationgt ltdeny users= gt ltallow users=30030895Aexamplecomgt ltauthorizationgt ltsystemwebgt ltconfigurationgt

This way only the admin user specified would be able to access that folder and its

subfolders

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 12: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

How to send email in ASPNET 20

Since version 20 ASPNET has a built in class (SystemNetMail) to send email See

the following code as example

C ASPNET

using SystemNetMail [hellip] MailMessage objEmail = new MailMessage( fromexamplecom toexamplecom This is the Subject This is the Body) objEmailPriority = MailPriorityNormal SmtpClient SMTPServer = new SmtpClient(localhost) try SMTPServerSend(objEmail) ResponseWrite(Email sent sucessfully) catch (Exception exc) ResponseWrite(Send failure + excToString())

VB ASPNET Imports SystemNetMail [hellip] Dim strFrom = fromexamplecom Dim strTo = toexamplecom Dim MailMsg As New MailMessage(New MailAddress(strFromTrim()) New MailAddress(strTo)) MailMsgSubject = This is the Subject MailMsgBody = This is the Body MailMsgPriority = MailPriorityNormal Dim SmtpMail As New SmtpClient SmtpMailHost = localhost Try SmtpMailSend(MailMsg) ResponseWrite(Email sent sucessfully) Catch exc As Exception ResponseWrite(excMessage) End Try

PHP ltphp

$to = toexamplecom

$subject = This is the subject

$body = This is the Body

$headers = From fromexamplecomrn

X-Mailer php

if (mail($to $subject $body $headers))

echo(ltpgtEmail sent successfullyltpgt)

else

echo(ltpgtMessage delivery failedltpgt)

gt

ASP NET 40 application error Unrecognized attribute ldquotargetFrameworkrdquo

If you find the following error when you attempt to open your web application

Description An error occurred during the processing of a configuration file required

to service this request Please review the specific error details below and modify your

configuration file appropriately

Parser Error Message Unrecognized attribute targetFramework Note that attribute

names are case-sensitive

The error indicates that your account is configured to run with the ASPNET 20

framework but your application is an ASPNET 40 application

To correct this simply login into MyAccount and under Windows Web IIS Admin

select 40 in the dropdown list named ldquoASPNET Versionrdquo as shown in the screen

below then click ldquoSet IIS propertiesrdquo

Install applications using Web Platform Installer

The Web Platform Installer provides easy installation of several popular web

applications to your web site This demonstration will show installation of a blog

system called Wordpress

Most applications requires a database If your product does not contain a database you

can contact Sales to get this If your database is not created you can do this from the

SQL section in MyAccount

The Web Platform Installer is a part of the IIS Manager for Remote

Administration tool

Web Platform Installer is a separate download from Microsoft The link to this is

located in MyAccount Windows Web Get Started

To start the Web Platform Installer open IIS Manager for Remote

Administration and go to Management section Double-click on the icon

The installer will use some seconds to load before starting

Choose either Whatrsquos new or Web Applications for browsing the applications

available for install

Web Applications has a several categories with types of applications

Click the information-icon to the right of application title to view more detailed

information about an application

This demonstration will install Wordpress from the Blogs section Click the Install

button when application has been chosen

A popup will list the application you have selected Click I Accept and the web

application will be downloaded

The next steps require information about your web site and database This information

can be found in MyAccount Passwords are sent to your domain names administrator

by e-mail

First enter a application name

To install the application on your web site root leave this box empty You will then

get a warning about the destination folder not being empty and you have to confirm to

overwrite existing files

Enter application name to install site in sub-folder Click Continue

The next and final step requires information about database passwords and other

important data

Important information

Some applications requires MSSQL and others MySQL database The Web

Platform Installer will show which database is required You need to go to the

correct product in MyAccount for information

In our example Wordpress requires MySQL

In the option Create a new or use an existing database it is important that you

choose Use existing database

Fill in information about database user password server location etc Click

Continue

If you get an error message about missing components (eg MySQL Connector for

Net) click the OK button

The site will be installed on web and database server and a confirmation page will be

displayed when completed

Click Launch to see site in browser and Finish to return to Web Platform Installer

If you want to install more than one application at once you can click more

checkboxes and then click Install The installation wizard will ask for information

required for each site chosen

How can I disable anonymous access to a folder and its subfolders in IIS75

It is possible to disable anonymous access to a specific folder and its subfolders To

do so simply create a webconfig file in that folder (or edit the existing one) with the

lines provided below It is required that Windows Authentication is enabled for

the site This must be done using the IIS 7 Manager ltxml version=10gt ltconfigurationgt ltsystemwebgt ltauthorizationgt ltdeny users= gt ltallow users=30030895Aexamplecomgt ltauthorizationgt ltsystemwebgt ltconfigurationgt

This way only the admin user specified would be able to access that folder and its

subfolders

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 13: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

PHP ltphp

$to = toexamplecom

$subject = This is the subject

$body = This is the Body

$headers = From fromexamplecomrn

X-Mailer php

if (mail($to $subject $body $headers))

echo(ltpgtEmail sent successfullyltpgt)

else

echo(ltpgtMessage delivery failedltpgt)

gt

ASP NET 40 application error Unrecognized attribute ldquotargetFrameworkrdquo

If you find the following error when you attempt to open your web application

Description An error occurred during the processing of a configuration file required

to service this request Please review the specific error details below and modify your

configuration file appropriately

Parser Error Message Unrecognized attribute targetFramework Note that attribute

names are case-sensitive

The error indicates that your account is configured to run with the ASPNET 20

framework but your application is an ASPNET 40 application

To correct this simply login into MyAccount and under Windows Web IIS Admin

select 40 in the dropdown list named ldquoASPNET Versionrdquo as shown in the screen

below then click ldquoSet IIS propertiesrdquo

Install applications using Web Platform Installer

The Web Platform Installer provides easy installation of several popular web

applications to your web site This demonstration will show installation of a blog

system called Wordpress

Most applications requires a database If your product does not contain a database you

can contact Sales to get this If your database is not created you can do this from the

SQL section in MyAccount

The Web Platform Installer is a part of the IIS Manager for Remote

Administration tool

Web Platform Installer is a separate download from Microsoft The link to this is

located in MyAccount Windows Web Get Started

To start the Web Platform Installer open IIS Manager for Remote

Administration and go to Management section Double-click on the icon

The installer will use some seconds to load before starting

Choose either Whatrsquos new or Web Applications for browsing the applications

available for install

Web Applications has a several categories with types of applications

Click the information-icon to the right of application title to view more detailed

information about an application

This demonstration will install Wordpress from the Blogs section Click the Install

button when application has been chosen

A popup will list the application you have selected Click I Accept and the web

application will be downloaded

The next steps require information about your web site and database This information

can be found in MyAccount Passwords are sent to your domain names administrator

by e-mail

First enter a application name

To install the application on your web site root leave this box empty You will then

get a warning about the destination folder not being empty and you have to confirm to

overwrite existing files

Enter application name to install site in sub-folder Click Continue

The next and final step requires information about database passwords and other

important data

Important information

Some applications requires MSSQL and others MySQL database The Web

Platform Installer will show which database is required You need to go to the

correct product in MyAccount for information

In our example Wordpress requires MySQL

In the option Create a new or use an existing database it is important that you

choose Use existing database

Fill in information about database user password server location etc Click

Continue

If you get an error message about missing components (eg MySQL Connector for

Net) click the OK button

The site will be installed on web and database server and a confirmation page will be

displayed when completed

Click Launch to see site in browser and Finish to return to Web Platform Installer

If you want to install more than one application at once you can click more

checkboxes and then click Install The installation wizard will ask for information

required for each site chosen

How can I disable anonymous access to a folder and its subfolders in IIS75

It is possible to disable anonymous access to a specific folder and its subfolders To

do so simply create a webconfig file in that folder (or edit the existing one) with the

lines provided below It is required that Windows Authentication is enabled for

the site This must be done using the IIS 7 Manager ltxml version=10gt ltconfigurationgt ltsystemwebgt ltauthorizationgt ltdeny users= gt ltallow users=30030895Aexamplecomgt ltauthorizationgt ltsystemwebgt ltconfigurationgt

This way only the admin user specified would be able to access that folder and its

subfolders

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 14: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

ASP NET 40 application error Unrecognized attribute ldquotargetFrameworkrdquo

If you find the following error when you attempt to open your web application

Description An error occurred during the processing of a configuration file required

to service this request Please review the specific error details below and modify your

configuration file appropriately

Parser Error Message Unrecognized attribute targetFramework Note that attribute

names are case-sensitive

The error indicates that your account is configured to run with the ASPNET 20

framework but your application is an ASPNET 40 application

To correct this simply login into MyAccount and under Windows Web IIS Admin

select 40 in the dropdown list named ldquoASPNET Versionrdquo as shown in the screen

below then click ldquoSet IIS propertiesrdquo

Install applications using Web Platform Installer

The Web Platform Installer provides easy installation of several popular web

applications to your web site This demonstration will show installation of a blog

system called Wordpress

Most applications requires a database If your product does not contain a database you

can contact Sales to get this If your database is not created you can do this from the

SQL section in MyAccount

The Web Platform Installer is a part of the IIS Manager for Remote

Administration tool

Web Platform Installer is a separate download from Microsoft The link to this is

located in MyAccount Windows Web Get Started

To start the Web Platform Installer open IIS Manager for Remote

Administration and go to Management section Double-click on the icon

The installer will use some seconds to load before starting

Choose either Whatrsquos new or Web Applications for browsing the applications

available for install

Web Applications has a several categories with types of applications

Click the information-icon to the right of application title to view more detailed

information about an application

This demonstration will install Wordpress from the Blogs section Click the Install

button when application has been chosen

A popup will list the application you have selected Click I Accept and the web

application will be downloaded

The next steps require information about your web site and database This information

can be found in MyAccount Passwords are sent to your domain names administrator

by e-mail

First enter a application name

To install the application on your web site root leave this box empty You will then

get a warning about the destination folder not being empty and you have to confirm to

overwrite existing files

Enter application name to install site in sub-folder Click Continue

The next and final step requires information about database passwords and other

important data

Important information

Some applications requires MSSQL and others MySQL database The Web

Platform Installer will show which database is required You need to go to the

correct product in MyAccount for information

In our example Wordpress requires MySQL

In the option Create a new or use an existing database it is important that you

choose Use existing database

Fill in information about database user password server location etc Click

Continue

If you get an error message about missing components (eg MySQL Connector for

Net) click the OK button

The site will be installed on web and database server and a confirmation page will be

displayed when completed

Click Launch to see site in browser and Finish to return to Web Platform Installer

If you want to install more than one application at once you can click more

checkboxes and then click Install The installation wizard will ask for information

required for each site chosen

How can I disable anonymous access to a folder and its subfolders in IIS75

It is possible to disable anonymous access to a specific folder and its subfolders To

do so simply create a webconfig file in that folder (or edit the existing one) with the

lines provided below It is required that Windows Authentication is enabled for

the site This must be done using the IIS 7 Manager ltxml version=10gt ltconfigurationgt ltsystemwebgt ltauthorizationgt ltdeny users= gt ltallow users=30030895Aexamplecomgt ltauthorizationgt ltsystemwebgt ltconfigurationgt

This way only the admin user specified would be able to access that folder and its

subfolders

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 15: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

Install applications using Web Platform Installer

The Web Platform Installer provides easy installation of several popular web

applications to your web site This demonstration will show installation of a blog

system called Wordpress

Most applications requires a database If your product does not contain a database you

can contact Sales to get this If your database is not created you can do this from the

SQL section in MyAccount

The Web Platform Installer is a part of the IIS Manager for Remote

Administration tool

Web Platform Installer is a separate download from Microsoft The link to this is

located in MyAccount Windows Web Get Started

To start the Web Platform Installer open IIS Manager for Remote

Administration and go to Management section Double-click on the icon

The installer will use some seconds to load before starting

Choose either Whatrsquos new or Web Applications for browsing the applications

available for install

Web Applications has a several categories with types of applications

Click the information-icon to the right of application title to view more detailed

information about an application

This demonstration will install Wordpress from the Blogs section Click the Install

button when application has been chosen

A popup will list the application you have selected Click I Accept and the web

application will be downloaded

The next steps require information about your web site and database This information

can be found in MyAccount Passwords are sent to your domain names administrator

by e-mail

First enter a application name

To install the application on your web site root leave this box empty You will then

get a warning about the destination folder not being empty and you have to confirm to

overwrite existing files

Enter application name to install site in sub-folder Click Continue

The next and final step requires information about database passwords and other

important data

Important information

Some applications requires MSSQL and others MySQL database The Web

Platform Installer will show which database is required You need to go to the

correct product in MyAccount for information

In our example Wordpress requires MySQL

In the option Create a new or use an existing database it is important that you

choose Use existing database

Fill in information about database user password server location etc Click

Continue

If you get an error message about missing components (eg MySQL Connector for

Net) click the OK button

The site will be installed on web and database server and a confirmation page will be

displayed when completed

Click Launch to see site in browser and Finish to return to Web Platform Installer

If you want to install more than one application at once you can click more

checkboxes and then click Install The installation wizard will ask for information

required for each site chosen

How can I disable anonymous access to a folder and its subfolders in IIS75

It is possible to disable anonymous access to a specific folder and its subfolders To

do so simply create a webconfig file in that folder (or edit the existing one) with the

lines provided below It is required that Windows Authentication is enabled for

the site This must be done using the IIS 7 Manager ltxml version=10gt ltconfigurationgt ltsystemwebgt ltauthorizationgt ltdeny users= gt ltallow users=30030895Aexamplecomgt ltauthorizationgt ltsystemwebgt ltconfigurationgt

This way only the admin user specified would be able to access that folder and its

subfolders

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 16: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

Choose either Whatrsquos new or Web Applications for browsing the applications

available for install

Web Applications has a several categories with types of applications

Click the information-icon to the right of application title to view more detailed

information about an application

This demonstration will install Wordpress from the Blogs section Click the Install

button when application has been chosen

A popup will list the application you have selected Click I Accept and the web

application will be downloaded

The next steps require information about your web site and database This information

can be found in MyAccount Passwords are sent to your domain names administrator

by e-mail

First enter a application name

To install the application on your web site root leave this box empty You will then

get a warning about the destination folder not being empty and you have to confirm to

overwrite existing files

Enter application name to install site in sub-folder Click Continue

The next and final step requires information about database passwords and other

important data

Important information

Some applications requires MSSQL and others MySQL database The Web

Platform Installer will show which database is required You need to go to the

correct product in MyAccount for information

In our example Wordpress requires MySQL

In the option Create a new or use an existing database it is important that you

choose Use existing database

Fill in information about database user password server location etc Click

Continue

If you get an error message about missing components (eg MySQL Connector for

Net) click the OK button

The site will be installed on web and database server and a confirmation page will be

displayed when completed

Click Launch to see site in browser and Finish to return to Web Platform Installer

If you want to install more than one application at once you can click more

checkboxes and then click Install The installation wizard will ask for information

required for each site chosen

How can I disable anonymous access to a folder and its subfolders in IIS75

It is possible to disable anonymous access to a specific folder and its subfolders To

do so simply create a webconfig file in that folder (or edit the existing one) with the

lines provided below It is required that Windows Authentication is enabled for

the site This must be done using the IIS 7 Manager ltxml version=10gt ltconfigurationgt ltsystemwebgt ltauthorizationgt ltdeny users= gt ltallow users=30030895Aexamplecomgt ltauthorizationgt ltsystemwebgt ltconfigurationgt

This way only the admin user specified would be able to access that folder and its

subfolders

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 17: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

The next steps require information about your web site and database This information

can be found in MyAccount Passwords are sent to your domain names administrator

by e-mail

First enter a application name

To install the application on your web site root leave this box empty You will then

get a warning about the destination folder not being empty and you have to confirm to

overwrite existing files

Enter application name to install site in sub-folder Click Continue

The next and final step requires information about database passwords and other

important data

Important information

Some applications requires MSSQL and others MySQL database The Web

Platform Installer will show which database is required You need to go to the

correct product in MyAccount for information

In our example Wordpress requires MySQL

In the option Create a new or use an existing database it is important that you

choose Use existing database

Fill in information about database user password server location etc Click

Continue

If you get an error message about missing components (eg MySQL Connector for

Net) click the OK button

The site will be installed on web and database server and a confirmation page will be

displayed when completed

Click Launch to see site in browser and Finish to return to Web Platform Installer

If you want to install more than one application at once you can click more

checkboxes and then click Install The installation wizard will ask for information

required for each site chosen

How can I disable anonymous access to a folder and its subfolders in IIS75

It is possible to disable anonymous access to a specific folder and its subfolders To

do so simply create a webconfig file in that folder (or edit the existing one) with the

lines provided below It is required that Windows Authentication is enabled for

the site This must be done using the IIS 7 Manager ltxml version=10gt ltconfigurationgt ltsystemwebgt ltauthorizationgt ltdeny users= gt ltallow users=30030895Aexamplecomgt ltauthorizationgt ltsystemwebgt ltconfigurationgt

This way only the admin user specified would be able to access that folder and its

subfolders

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 18: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

The next and final step requires information about database passwords and other

important data

Important information

Some applications requires MSSQL and others MySQL database The Web

Platform Installer will show which database is required You need to go to the

correct product in MyAccount for information

In our example Wordpress requires MySQL

In the option Create a new or use an existing database it is important that you

choose Use existing database

Fill in information about database user password server location etc Click

Continue

If you get an error message about missing components (eg MySQL Connector for

Net) click the OK button

The site will be installed on web and database server and a confirmation page will be

displayed when completed

Click Launch to see site in browser and Finish to return to Web Platform Installer

If you want to install more than one application at once you can click more

checkboxes and then click Install The installation wizard will ask for information

required for each site chosen

How can I disable anonymous access to a folder and its subfolders in IIS75

It is possible to disable anonymous access to a specific folder and its subfolders To

do so simply create a webconfig file in that folder (or edit the existing one) with the

lines provided below It is required that Windows Authentication is enabled for

the site This must be done using the IIS 7 Manager ltxml version=10gt ltconfigurationgt ltsystemwebgt ltauthorizationgt ltdeny users= gt ltallow users=30030895Aexamplecomgt ltauthorizationgt ltsystemwebgt ltconfigurationgt

This way only the admin user specified would be able to access that folder and its

subfolders

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 19: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

If you get an error message about missing components (eg MySQL Connector for

Net) click the OK button

The site will be installed on web and database server and a confirmation page will be

displayed when completed

Click Launch to see site in browser and Finish to return to Web Platform Installer

If you want to install more than one application at once you can click more

checkboxes and then click Install The installation wizard will ask for information

required for each site chosen

How can I disable anonymous access to a folder and its subfolders in IIS75

It is possible to disable anonymous access to a specific folder and its subfolders To

do so simply create a webconfig file in that folder (or edit the existing one) with the

lines provided below It is required that Windows Authentication is enabled for

the site This must be done using the IIS 7 Manager ltxml version=10gt ltconfigurationgt ltsystemwebgt ltauthorizationgt ltdeny users= gt ltallow users=30030895Aexamplecomgt ltauthorizationgt ltsystemwebgt ltconfigurationgt

This way only the admin user specified would be able to access that folder and its

subfolders

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 20: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

If you want to install more than one application at once you can click more

checkboxes and then click Install The installation wizard will ask for information

required for each site chosen

How can I disable anonymous access to a folder and its subfolders in IIS75

It is possible to disable anonymous access to a specific folder and its subfolders To

do so simply create a webconfig file in that folder (or edit the existing one) with the

lines provided below It is required that Windows Authentication is enabled for

the site This must be done using the IIS 7 Manager ltxml version=10gt ltconfigurationgt ltsystemwebgt ltauthorizationgt ltdeny users= gt ltallow users=30030895Aexamplecomgt ltauthorizationgt ltsystemwebgt ltconfigurationgt

This way only the admin user specified would be able to access that folder and its

subfolders

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 21: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

How can I disable anonymous access to a folder and its subfolders in IIS75

It is possible to disable anonymous access to a specific folder and its subfolders To

do so simply create a webconfig file in that folder (or edit the existing one) with the

lines provided below It is required that Windows Authentication is enabled for

the site This must be done using the IIS 7 Manager ltxml version=10gt ltconfigurationgt ltsystemwebgt ltauthorizationgt ltdeny users= gt ltallow users=30030895Aexamplecomgt ltauthorizationgt ltsystemwebgt ltconfigurationgt

This way only the admin user specified would be able to access that folder and its

subfolders

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 22: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

How to redirect a subdomain to a subfolder

In this example we have a domain called ldquoexamplecomrdquo with two hostnames

wwwexamplecom (examplecom)

shopexamplecom

Note Hostnames can be Added in MyAccount control panel under ldquoDomain Adminrdquo

We have created the following directory structure at our site

wwwrootdefaultaspx (landing page for wwwexamplecom)

wwwrootwebconfig (config file for the root application)

wwwrootshopdefaultaspx (required landing page for shopexamplecom)

In order to redirect incoming requests on ldquoshopexamplecomrdquo to a subfolder called

ldquoshoprdquo we add the following to the webconfig file located at wwwrootwebconfig

ltsystemwebServergt ltrewritegt ltrulesgt ltrule name=Shop Subdomain Redirect stopProcessing=truegt ltmatch url=() gt ltconditions logicalGrouping=MatchAllgt ltadd input=HTTP_HOST pattern=^shopexamplecom$ gt ltadd input=REQUEST_URI negate=true pattern=shop gt ltconditionsgt ltaction type=Redirect url=httpshopexamplecomshopR1 gt ltrulegt ltrulesgt ltrewritegt ltsystemwebServergt

Incoming request to

wwwexamplecom (examplecom) will then load contents from wwwroot

Incoming requests to shopexamplecom will then load contents from wwwrootshop

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 23: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

Why canrsquot I delete all files from WebDAV

The following files are configured at server level to be denied from manupilation on

WebDAV

ltrequestFilteringgt

ltfileExtensions allowUnlisted=true applyToWebDAV=truegt

ltadd fileExtension=asax allowed=false gt

ltadd fileExtension=ascx allowed=false gt

ltadd fileExtension=master allowed=false gt

ltadd fileExtension=skin allowed=false gt

ltadd fileExtension=browser allowed=false gt

ltadd fileExtension=sitemap allowed=false gt

ltadd fileExtension=config allowed=false gt

ltadd fileExtension=cs allowed=false gt

ltadd fileExtension=csproj allowed=false gt

ltadd fileExtension=vb allowed=false gt

ltadd fileExtension=vbproj allowed=false gt

ltadd fileExtension=webinfo allowed=false gt

ltadd fileExtension=licx allowed=false gt

ltadd fileExtension=resx allowed=false gt

ltadd fileExtension=resources allowed=false gt

ltadd fileExtension=mdb allowed=false gt

ltadd fileExtension=vjsproj allowed=false gt

ltadd fileExtension=java allowed=false gt

ltadd fileExtension=jsl allowed=false gt

ltadd fileExtension=ldb allowed=false gt

ltadd fileExtension=dsdgm allowed=false gt

ltadd fileExtension=ssdgm allowed=false gt

ltadd fileExtension=lsad allowed=false gt

ltadd fileExtension=ssmap allowed=false gt

ltadd fileExtension=cd allowed=false gt

ltadd fileExtension=dsprototype allowed=false gt

ltadd fileExtension=lsaprototype allowed=false gt

ltadd fileExtension=sdm allowed=false gt

ltadd fileExtension=sdmDocument allowed=false gt

ltadd fileExtension=mdf allowed=false gt

ltadd fileExtension=ldf allowed=false gt

ltadd fileExtension=ad allowed=false gt

ltadd fileExtension=dd allowed=false gt

ltadd fileExtension=ldd allowed=false gt

ltadd fileExtension=sd allowed=false gt

ltadd fileExtension=adprototype allowed=false gt

ltadd fileExtension=lddprototype allowed=false gt

ltadd fileExtension=exclude allowed=false gt

ltadd fileExtension=refresh allowed=false gt

ltadd fileExtension=compiled allowed=false gt

ltadd fileExtension=msgx allowed=false gt

ltadd fileExtension=vsdisco allowed=false gt

ltadd fileExtension=rules allowed=false gt

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 24: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

ltadd fileExtension=asa allowed=false gt

ltfileExtensionsgt

ltverbs allowUnlisted=true applyToWebDAV=true gt

lthiddenSegments applyToWebDAV=truegt

ltadd segment=webconfig gt

ltadd segment=bin gt

ltadd segment=App_code gt

ltadd segment=App_GlobalResources gt

ltadd segment=App_LocalResources gt

ltadd segment=App_WebReferences gt

ltadd segment=App_Data gt

ltadd segment=App_Browsers gt

lthiddenSegmentsgt

ltrequestFilteringgt

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 25: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

How to add Google Analytics to your website

1) Sign up for a Google Analytics profile for your site You can do this on

httpwwwgooglecomanalytics

2) Open your IIS Manager and look for the module called ldquoURL Rewriterdquo

3) Select the action called ldquoAdd Rulerdquo from the upper right corner and select a

ldquoblank rulerdquo under ldquoOutbound rulesrdquo as follows

4) Give the outgoing rule a logical name and create a new precondition as

follows

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 26: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

5) Select the condition input type match type and pattern as follows

6) You should end up with a precondition looking roughly as follows

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 27: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

7)

8) You should now setup what you should match The main thing to remember is

that you must use an exact match and the pattern should be ldquoltbodygtrdquo You

should also ignore case and end up with the following

9) The value of Action Properties should be the following (although you need to

substitute ldquoUA-xxxxxx-xrdquo with the profile ID you got in step 1)

a ltscript type=textjavascriptgtvar gaJsHost = ((https == documentlocationprotocol)

httpsssl

httpwww)documentwrite(unescape(3Cscri

pt src= + gaJsHost + google-

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt

Page 28: Windows Server 2008 (IIS 7.5) - FAQ - ACTIVE 24 UK · How to connect with FTP over SSL using the FileZilla FTP client Windows 2008 R2/IIS 7.5 allows a secure FTP connection via FTP

analyticscomgajs

type=textjavascript3E3Cscript3E))ltscr

iptgtltscript type=textjavascriptgttryvar

pageTracker = _gat_getTracker(UA-xxxxxx-

x)pageTracker_trackPageview() catch(err)

ltscriptgtltbodygt

10) You can confirm this by verifying that webconfig contains the following

segment ltrewritegt

ltoutboundRulesgt

ltrule name=Add Google Analytics Code

preCondition=IsHTML patternSyntax=ExactMatchgt

ltmatch pattern=ampltbodygt gt

ltaction type=Rewrite value=ampltscript

type=ampquottextjavascriptampquotgtvar gaJsHost =

((ampquothttpsampquot == documentlocationprotocol)

ampquothttpssslampquot

ampquothttpwwwampquot)documentwrite(unescape(ampquot3Cscript

src=ampquot + gaJsHost + ampquotgoogle-analyticscomgajs

type=textjavascript3E3Cscript3Eampquot))ampltscriptgtampltscr

ipt type=ampquottextjavascriptampquotgtvar pageTracker =

_gat_getTracker(ampquotUA-xxxxxx-

xampquot)pageTracker_initData()pageTracker_trackPageview()amplt

scriptgtampltbodygt gt

ltrulegt

ltpreConditionsgt

ltpreCondition name=IsHTMLgt

ltadd input=RESPONSE_CONTENT_TYPE

pattern=^texthtml gt

ltpreConditiongt

ltpreConditionsgt

ltoutboundRulesgt

ltrewritegt