[Mono-bugs] [Bug 57736][Nor] New - Incorrect path when using tilde in aspx page in a subdirectory

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Tue, 27 Apr 2004 16:00:34 -0400 (EDT)


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by peter@eringal.com.

http://bugzilla.ximian.com/show_bug.cgi?id=57736

--- shadow/57736	2004-04-27 16:00:34.000000000 -0400
+++ shadow/57736.tmp.24293	2004-04-27 16:00:34.000000000 -0400
@@ -0,0 +1,89 @@
+Bug#: 57736
+Product: Mono: Class Libraries
+Version: unspecified
+OS: 
+OS Details: Slackware Linux 9.1
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Normal
+Component: Sys.Web
+AssignedTo: mono-bugs@ximian.com                            
+ReportedBy: peter@eringal.com               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: Incorrect path when using tilde in aspx page in a subdirectory
+
+Description of Problem:
+When a tilde is used to refer to an ascx file in another directory, the
+path that xsp attempts to open is not correct. Example:
+
+Server Error in '/' Application
+Parser Error
+Description: Error parsing a resource required to service this request.
+Review your source file and modify it to fix this error.
+
+Error message: Could not find file
+"/home/peter/bugtest/SubDirControls/blap.ascx".
+
+File name: /home/peter/bugtest/SubDir/tildebug.aspx    Line: 2
+
+Source Error:
+
+<%@ Page language="c#" AutoEventWireup="false" %>
+<%@ Register TagPrefix="arg" TagName="blap" Src="~\Controls\blap.ascx" %>
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" > 
+
+<html>
+
+This problem does not occur using MS.NET 1.1
+
+Steps to reproduce the problem:
+1. Create a directory called "bugtest". In it, create two more directories:
+"SubDir" and "Controls".
+2. In SubDir create a file called tildebug.aspx. Here are the contents:
+<%@ Page language="c#" AutoEventWireup="false" %>
+<%@ Register TagPrefix="arg" TagName="blap" Src="~\Controls\blap.ascx" %>
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" > 
+
+<html>
+	<head>
+		<title>bug</title>
+	</head>
+	<body bgcolor="#FFFFFF" text="#000000">
+
+		<form id="df" method="post" runat="server">
+			<arg:blap Runat=server />
+		</form>
+
+	</body>
+</html>
+
+3. In Controls, create a file called blap.ascx. Its contents:
+<%@ Control Language="c#" AutoEventWireup="false"
+TargetSchema="http://schemas.microsoft.com/intellisense/ie5"%>
+<p>I am the blap control</p>
+
+4. Go to the bugtest directory and run xsp.
+5. Browse to http://localhost:8080/SubDir/tildebug.aspx and you will see
+the error.
+
+Actual Results:
+xsp attempts to open /home/peter/bugtest/SubDirControls/blap.ascx when it
+should be opening home/peter/bugtest/Controls/blap.ascx
+
+Expected Results:
+An html page displaying "I am the blap control" should appear.
+
+
+How often does this happen? 
+Everytime.
+
+
+Additional Information:
+A couple of web apps that I work on in Windows have similar layouts, with
+aspx pages under subdirectory of the main application and some ascx
+controls in a different subdirectory. This would greatly ease porting these
+applications to linux.