Includes

J

Jeff

I have an asp page. Now I know this is sortof OT, but I am not sure of the
forum to get an answer.

I have an include on this asp page

<!-- #include file=\forum\includes\consts-inc.asp -->

now, it gives me this error:
File attribute '\forum\includes\consts-inc.asp' cannot start with forward
slash or back slash.

i can't use .. either, because it gives me this error:The Include file
'..\forum\includes\consts-inc.asp' cannot contain '..' to indicate the
parent directory.

I tried with the slashes going / and \

if i use this:
<!-- #include file=forum/includes/consts-inc.asp -->
i get this:
The include file 'forum/includes/consts-inc.asp' was not found.

for some information. i the file that gives the error is in the includes
folder, which is in the root web. the forum folder is also in the root web.

so i am in folder unthe root, and trying to include a file from another
folder under the root.

how can i do this??



thanks in advance

Jeff
 
M

Mike Brind

Jeff said:
I have an asp page. Now I know this is sortof OT, but I am not sure of the
forum to get an answer.

I have an include on this asp page

<!-- #include file=\forum\includes\consts-inc.asp -->

now, it gives me this error:
File attribute '\forum\includes\consts-inc.asp' cannot start with forward
slash or back slash.

i can't use .. either, because it gives me this error:The Include file
'..\forum\includes\consts-inc.asp' cannot contain '..' to indicate the
parent directory.

I tried with the slashes going / and \

if i use this:
<!-- #include file=forum/includes/consts-inc.asp -->
i get this:
The include file 'forum/includes/consts-inc.asp' was not found.

for some information. i the file that gives the error is in the includes
folder, which is in the root web. the forum folder is also in the root web.

Is includes in the web root or in the forums directory? What you've
said is contradictory. If your includes is really in the web root do
this:

<!--#include virtual="includes/consts-inc.asp"-->

If it is in the forums directory, which is in web root, do this:

<!--#include virtual="forums/includes/consts-inc.asp"-->

Oh, and your question is not OT. It's a general ASP question :)
 
M

Mike Brind

Jeff said:
well.. the forums is in the root... and of course forums/includes
isn't. my bad for wording that wrong.
i have this
<!--#include virtual="forums/includes/consts-inc.asp"-->
and still getting this

Include file not found

/includes/forum-inc.asp, line 37

The include file 'forums/includes/consts-inc.asp' was not found.

forums - plural
i looked over the permissions and i don't see
anything about parent paths.

i know the file is there, as here is the path copied straight from
the tree.

http://my.domain/forum/includes/consts-inc.asp

forum - singular


So which is it? Is the directory called forum or forums (plural)?
That's probably why the file can't be found.

Please make sure you reply to the newsgroup in future, not the
spam-trap email address I use here. The delay in responding is because
I hardly ever look at that email account. Lucky for you, I was kind of
bored this morning :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,995
Messages
2,570,228
Members
46,817
Latest member
AdalbertoT

Latest Threads

Top