Hello all.. I'm working on an application that I'd like to use some shared
files.
Right now my directory structure is:
/ (root)
.../Shared/
.../Reports/
.../Tools/
I would like to have CSS, shared functions etc.. in the shared folder and
use them in the root, reports and tools.
So.. in my dev environment I don't have a problem, but I have a remote
developer that wants to install in a subdirectory.. so all my includes don't
work..
<!--#INCLUDE FILE="shared/Common.asp"-->
should I change to virtual? I'm stuck on how to make this work in both
installing in a root web situation, and a sub directory situation.
Thoughts? 13 2545
Use absolute paths for common elements (includes, stylesheets, etc.) than
relative paths. Takes care of many problems than you know :)
--
Manohar Kamath
Editor, .netWire www.dotnetwire.com
"Bryan Harrington" <ne**@psacake.com> wrote in message
news:eu**************@TK2MSFTNGP11.phx.gbl... Hello all.. I'm working on an application that I'd like to use some shared files.
Right now my directory structure is:
/ (root) .../Shared/ .../Reports/ .../Tools/
I would like to have CSS, shared functions etc.. in the shared folder and use them in the root, reports and tools.
So.. in my dev environment I don't have a problem, but I have a remote developer that wants to install in a subdirectory.. so all my includes
don't work..
<!--#INCLUDE FILE="shared/Common.asp"-->
should I change to virtual? I'm stuck on how to make this work in both installing in a root web situation, and a sub directory situation.
Thoughts?
> <!--#INCLUDE FILE="shared/Common.asp"--> should I change to virtual? I'm stuck on how to make this work in both installing in a root web situation, and a sub directory situation.
<!--#include virtual="/shared/common.asp"-->
FWIW, I *always* include this way. I never use FILE...
--
Aaron Bertrand
SQL Server MVP http://www.aspfaq.com/
Do you mean <!--#include file="c:\inetpub\wwwroot\shared\common.css"-->
?
If so, I can think of at least one problems with this, and that is that your
web host might change the location of the webroot, or create virtual
directories to some or all of your files.
If you have a sane directory structure, referencing virtual from the root
should work perfectly, and isn't vulnerable to changes to the actual file
system.
--
Aaron Bertrand
SQL Server MVP http://www.aspfaq.com/
"Manohar Kamath [MVP]" <mk*****@TAKETHISOUTkamath.com> wrote in message
news:ef**************@TK2MSFTNGP10.phx.gbl... Use absolute paths for common elements (includes, stylesheets, etc.) than relative paths. Takes care of many problems than you know :)
-- Manohar Kamath Editor, .netWire www.dotnetwire.com
"Bryan Harrington" <ne**@psacake.com> wrote in message news:eu**************@TK2MSFTNGP11.phx.gbl... Hello all.. I'm working on an application that I'd like to use some shared files.
Right now my directory structure is:
/ (root) .../Shared/ .../Reports/ .../Tools/
I would like to have CSS, shared functions etc.. in the shared folder and use them in the root, reports and tools.
So.. in my dev environment I don't have a problem, but I have a remote developer that wants to install in a subdirectory.. so all my includes don't work..
<!--#INCLUDE FILE="shared/Common.asp"-->
should I change to virtual? I'm stuck on how to make this work in both installing in a root web situation, and a sub directory situation.
Thoughts?
Well.. that's part of my problem I suppose.. I don't know what the absolute
path will be if the end user decides to install it in a subdirectory instead
of it's own virtual web.
"Manohar Kamath [MVP]" <mk*****@TAKETHISOUTkamath.com> wrote in message
news:ef**************@TK2MSFTNGP10.phx.gbl... Use absolute paths for common elements (includes, stylesheets, etc.) than relative paths. Takes care of many problems than you know :)
-- Manohar Kamath Editor, .netWire www.dotnetwire.com
"Bryan Harrington" <ne**@psacake.com> wrote in message news:eu**************@TK2MSFTNGP11.phx.gbl... Hello all.. I'm working on an application that I'd like to use some
shared files.
Right now my directory structure is:
/ (root) .../Shared/ .../Reports/ .../Tools/
I would like to have CSS, shared functions etc.. in the shared folder
and use them in the root, reports and tools.
So.. in my dev environment I don't have a problem, but I have a remote developer that wants to install in a subdirectory.. so all my includes don't work..
<!--#INCLUDE FILE="shared/Common.asp"-->
should I change to virtual? I'm stuck on how to make this work in both installing in a root web situation, and a sub directory situation.
Thoughts?
I meant <!--#include virtual="/common/include.asp" -->
The problem with relative paths is, the files could move from one directory
to another, and you need to change them unnecessarily.
--
Manohar Kamath
Editor, .netWire www.dotnetwire.com
"Aaron Bertrand [MVP]" <aa***@TRASHaspfaq.com> wrote in message
news:%2****************@tk2msftngp13.phx.gbl... Do you mean <!--#include file="c:\inetpub\wwwroot\shared\common.css"--> ?
If so, I can think of at least one problems with this, and that is that
your web host might change the location of the webroot, or create virtual directories to some or all of your files.
If you have a sane directory structure, referencing virtual from the root should work perfectly, and isn't vulnerable to changes to the actual file system.
-- Aaron Bertrand SQL Server MVP http://www.aspfaq.com/
"Manohar Kamath [MVP]" <mk*****@TAKETHISOUTkamath.com> wrote in message news:ef**************@TK2MSFTNGP10.phx.gbl... Use absolute paths for common elements (includes, stylesheets, etc.)
than relative paths. Takes care of many problems than you know :)
-- Manohar Kamath Editor, .netWire www.dotnetwire.com
"Bryan Harrington" <ne**@psacake.com> wrote in message news:eu**************@TK2MSFTNGP11.phx.gbl... Hello all.. I'm working on an application that I'd like to use some shared files.
Right now my directory structure is:
/ (root) .../Shared/ .../Reports/ .../Tools/
I would like to have CSS, shared functions etc.. in the shared folder and use them in the root, reports and tools.
So.. in my dev environment I don't have a problem, but I have a remote developer that wants to install in a subdirectory.. so all my includes don't work..
<!--#INCLUDE FILE="shared/Common.asp"-->
should I change to virtual? I'm stuck on how to make this work in both installing in a root web situation, and a sub directory situation.
Thoughts?
If that's the case, you are better off with a relative path. Actually,
unless you don't move your files around that much, you shouldn't have a
problem.
e.g.
<!--#include virtual="../common/include.asp"-->
--
Manohar Kamath
Editor, .netWire www.dotnetwire.com
"Bryan Harrington" <ne**@psacake.com> wrote in message
news:eI**************@TK2MSFTNGP10.phx.gbl... Well.. that's part of my problem I suppose.. I don't know what the
absolute path will be if the end user decides to install it in a subdirectory
instead of it's own virtual web.
"Manohar Kamath [MVP]" <mk*****@TAKETHISOUTkamath.com> wrote in message news:ef**************@TK2MSFTNGP10.phx.gbl... Use absolute paths for common elements (includes, stylesheets, etc.)
than relative paths. Takes care of many problems than you know :)
-- Manohar Kamath Editor, .netWire www.dotnetwire.com
"Bryan Harrington" <ne**@psacake.com> wrote in message news:eu**************@TK2MSFTNGP11.phx.gbl... Hello all.. I'm working on an application that I'd like to use some shared files.
Right now my directory structure is:
/ (root) .../Shared/ .../Reports/ .../Tools/
I would like to have CSS, shared functions etc.. in the shared folder and use them in the root, reports and tools.
So.. in my dev environment I don't have a problem, but I have a remote developer that wants to install in a subdirectory.. so all my includes
don't work..
<!--#INCLUDE FILE="shared/Common.asp"-->
should I change to virtual? I'm stuck on how to make this work in both installing in a root web situation, and a sub directory situation.
Thoughts?
Okay, I was confused because that is not an "absolute" path... what you're
demonstrating is, actually, a relative path.
--
Aaron Bertrand
SQL Server MVP http://www.aspfaq.com/
"Manohar Kamath [MVP]" <mk*****@TAKETHISOUTkamath.com> wrote in message
news:OI*************@tk2msftngp13.phx.gbl... I meant <!--#include virtual="/common/include.asp" -->
The problem with relative paths is, the files could move from one
directory to another, and you need to change them unnecessarily.
I think it is the semantics... the /common/includes is an absolute path
although the domain has been left off. But one can argue it is relative to
the root.
--
Manohar Kamath
Editor, .netWire www.dotnetwire.com
"Aaron Bertrand - MVP" <aa***@TRASHaspfaq.com> wrote in message
news:%2****************@TK2MSFTNGP10.phx.gbl... Okay, I was confused because that is not an "absolute" path... what you're demonstrating is, actually, a relative path.
-- Aaron Bertrand SQL Server MVP http://www.aspfaq.com/
"Manohar Kamath [MVP]" <mk*****@TAKETHISOUTkamath.com> wrote in message news:OI*************@tk2msftngp13.phx.gbl... I meant <!--#include virtual="/common/include.asp" -->
The problem with relative paths is, the files could move from one directory to another, and you need to change them unnecessarily.
On Tue, 30 Mar 2004 07:20:16 -0600, "Manohar Kamath [MVP]"
<mk*****@TAKETHISOUTkamath.com> wrote: I think it is the semantics... the /common/includes is an absolute path although the domain has been left off. But one can argue it is relative to the root.
No, it's a relative path. Absolute paths are specified absolutely.
:)
Jeff
I did specify is absolutely, it is not relative to anything.
If I specified it as ../common/includes.asp, then it would be relative, cos
it can only work with files that are in a certain folder. http://webdesign.about.com/library/weekly/aa040502a.htm
--
Manohar Kamath
Editor, .netWire www.dotnetwire.com
"Jeff Cochran" <jc*************@naplesgov.com> wrote in message
news:40****************@msnews.microsoft.com... On Tue, 30 Mar 2004 07:20:16 -0600, "Manohar Kamath [MVP]" <mk*****@TAKETHISOUTkamath.com> wrote:
I think it is the semantics... the /common/includes is an absolute path although the domain has been left off. But one can argue it is relative
tothe root.
No, it's a relative path. Absolute paths are specified absolutely. :)
Jeff
>I did specify is absolutely, it is not relative to anything.
Yes, / is relative to the root. Absolute means "FULL PATH"
A
At best, it is relative to the domain (say www.something.com). It is not
relative to the root, since you mention the root in the path.
--
Manohar Kamath
Editor, .netWire www.dotnetwire.com
"Aaron Bertrand [MVP]" <aa***@TRASHaspfaq.com> wrote in message
news:uC**************@TK2MSFTNGP10.phx.gbl... I did specify is absolutely, it is not relative to anything.
Yes, / is relative to the root. Absolute means "FULL PATH"
A
/folder/file.asp is relative to the root
.../folder/file.asp is relative to the current folder
Absolute would say http://www.something.com/folder/file.asp or
c:\inetpub\wwwroot\folder\file.css
But I don't feel like arguing anymore, so you win, if you want.
--
Aaron Bertrand
SQL Server MVP http://www.aspfaq.com/
"Manohar Kamath [MVP]" <mk*****@TAKETHISOUTkamath.com> wrote in message
news:ue**************@TK2MSFTNGP10.phx.gbl... At best, it is relative to the domain (say www.something.com). It is not relative to the root, since you mention the root in the path. This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Simon |
last post by:
Hi,
I have one question:
I used to do a lot with asp and now I'm going to use asp.net technology
In asp I had a file functions.asp with all my functions I used on several
pages like generating...
|
by: Frank |
last post by:
Hi,
It is possible to add variable into the include file.
<!--#include file="../info/<%=strfoldername%>/notetosomeone.asp"-->
strfoldername is from my database.
It doesn't work.
Anyone knows...
|
by: Astra |
last post by:
Hi All
Could you please confirm whether it is possible to include an include file,
which is on another site, but still on the same set of web servers.
I want to upload a default paeg to a...
|
by: Jonathan LaRosa |
last post by:
Hi all -
I would like to do something like this:
<!--#include file="C:\dbutils\dbConfig.asp"-->
Where the directory C:\dbutils is OUTSIDE of the web directory and not
accessible by a client...
|
by: JR |
last post by:
Hi, I'm migrating my website to an IIS 6.0 server and all
the asp pages work fine except for the ones that reference
include files, even though I have "Enable parent paths"
enabled in the...
|
by: qaz |
last post by:
I run a web site on both a testing server and a "production" server. I
noticed that references to the include file do not work on the testing
server but they do work on the production server. I...
|
by: Eric |
last post by:
Hello,
I have some server side includes on a Classic asp page that look
something like:
<!-- #include virtual="/includes/file1.asp"-->
<!-- #include virtual="/includes/file2.asp" -->
<!--...
|
by: SteveT |
last post by:
Is it possible to have an include file that resides outside of the web site
parent folder?
For instance, lets say you have several websites under
Inetpub/global/websites/ but the include file is...
|
by: armando |
last post by:
Hi, I'm working on a web site devolepped in asp and this site work
with the incusion in the page asp
<td id="Colonna lato sinistro" width="200px" valign="top"
style="height: 19px">
<!--#include...
|
by: Faith0G |
last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
|
by: taylorcarr |
last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: ryjfgjl |
last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
| |