Sunday, June 14, 2009

The Include file '.asp' cannot contain '..' to indicate the parent directory.

The Problem

Active Server Pages error 'ASP 0131'

Disallowed Parent Path

login.asp, line 1

The Include file '../dbconn.asp' cannot contain '..' to indicate the parent directory.

Solution

The best solution to the problem is to use exact paths of the include files instead of relative paths.

An alternative way to using absolute virtual paths is to enable parent paths in the Inet manager; But, this is not the preferred method.

Internet Information Services 7.0

  • Start Internet Services Manager. - run->inetmgr
  • Click Default Web Site, and then click Properties.
  • Double-click ASP in the Features pane.
  • Expand Behavior.
  • Click Enable Parent Paths.
  • Click True for Enable Parent Paths.
  • Click Apply.

Internet Information Services 6.0
  • Open the Internet Services Manager. - run->inetmgr
  • Right-click on your Default Web Site and select Properties.
  • Click the Home Directory tab.
  • Click the Configuration button.
  • Click the App Options tab.
  • Click to select the Enable Parent Paths checkbox.
  • Click the OK button.

0 Comments: