T
tshad
I have an ascx file I am using to include my logos and heading information
for all my pages.
It was working fine up until now.
I decided to set up an admin folder inside of my main folder and move one of
my files into it - now my links don't work.
I have a setup:
development
images
includes
staffing
admin
To get to my includes folder (where the ascx file is) I would use;
<%@ Register TagPrefix="fts" TAgName="header"
src="..\includes\ClientHeaders.ascx" %>
This worked fine.
But now I have the file in a folder one level down inside my staffing folder
(admin).
I now change the entry to:
<%@ Register TagPrefix="fts" TAgName="header"
src="..\..\includes\ClientHeaders.ascx" %>
This works fine as far as finding the file. The problem is that the
relative paths are not relative to where the ascx file is but where my aspx
page is (which is now one level down).
For example, in my ClientHeaders.ascx file I have the following:
<table width="100%" class="tableMain" border="0" cellspacing="0"
cellpadding="0">
<tr width="424" height="90" valign="top">
<td width="424px"><img src="..\images\masthead3.jpg" width="246"
height="74px">
It can fine the masthead3.jpg fine from staffing (where it used to be). But
now the file is really "..\..\images\masthead3.jpg".
How do I use the sam ascx file in both folders (or can I)?
Thanks,
Tom
for all my pages.
It was working fine up until now.
I decided to set up an admin folder inside of my main folder and move one of
my files into it - now my links don't work.
I have a setup:
development
images
includes
staffing
admin
To get to my includes folder (where the ascx file is) I would use;
<%@ Register TagPrefix="fts" TAgName="header"
src="..\includes\ClientHeaders.ascx" %>
This worked fine.
But now I have the file in a folder one level down inside my staffing folder
(admin).
I now change the entry to:
<%@ Register TagPrefix="fts" TAgName="header"
src="..\..\includes\ClientHeaders.ascx" %>
This works fine as far as finding the file. The problem is that the
relative paths are not relative to where the ascx file is but where my aspx
page is (which is now one level down).
For example, in my ClientHeaders.ascx file I have the following:
<table width="100%" class="tableMain" border="0" cellspacing="0"
cellpadding="0">
<tr width="424" height="90" valign="top">
<td width="424px"><img src="..\images\masthead3.jpg" width="246"
height="74px">
It can fine the masthead3.jpg fine from staffing (where it used to be). But
now the file is really "..\..\images\masthead3.jpg".
How do I use the sam ascx file in both folders (or can I)?
Thanks,
Tom