Re: Using [Include] Context

This WebDNA talk-list message is from

1999


It keeps the original formatting.
numero = 24677
interpreted = N
texte = The key is in how you interpret the word relative in this context. Relative to the current document, or relative to the root. Webcatalog is expecting the former. On NT, root relative is further confused by the fact that the leading slash in the path actually points to the Webcatalog directory in the scripts directory, instead of the expected web site root. What you need to do is create a document relative path, such as [include file=../include/filename.txt] which will work on all platforms. In fact, in html as well as webdna, using root relative or semi-qualified paths can, and usually will, make your web site non-portable. References such as src=/images/header.gif will lock your web site in the directory structure that it's in now, needing code revision to move the site to a new server that may use different server software or directory structures. Simple answer: where possible, always use ../filepath/ (document relative) file paths instead of /filepath/ (root relative) file paths, whether in your WebDNA or in your HTML.Mike> From: Vince Medina > Reply-To: (WebCatalog Talk) > Date: Thu, 11 Nov 1999 21:52:30 > To: (WebCatalog Talk) > Subject: Using [Include] Context > > When using an [include file=/include/filename.txt] > We get a file not found error. > > As I understand the syntax, the path should be relative to virtual root path > where my htdocs dir is. > > For example: If the site is www.test.com then it should include a file > located in http://www.test.com/include/filename.txt > > Is there something I am missing? > > Vince > > > APC Net, Inc. - sales@apcn.net - www.apcn.net > 4471 NW 36 St. #110 - Miami Springs, FL 33166 > > > > ------------------------------------------------------------- > Brought to you by CommuniGate Pro - The Buzz Word Compliant Messaging Server. > To end your Mail problems go to . > > This message is sent to you because you are subscribed to > the mailing list . > To unsubscribe, E-mail to: > To switch to the DIGEST mode, E-mail to > ------------------------------------------------------------- Brought to you by CommuniGate Pro - The Buzz Word Compliant Messaging Server. To end your Mail problems go to .This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Associated Messages, from the most recent to the oldest:

    
  1. Re[2]: Using [Include] Context ( 1999)
  2. Re: Using [Include] Context (Mike_Davis 1999)
  3. Re[2]: Using [Include] Context ( 1999)
  4. Re: Re[2]: Using [Include] Context (J. A. Hill 1999)
  5. Re[2]: Using [Include] Context ( 1999)
  6. Re: Using [Include] Context (John Hill 1999)
  7. Re: Using [Include] Context (Bob Minor 1999)
  8. Re: Using [Include] Context (Vince Medina 1999)
  9. Re: Using [Include] Context (Nicolas Verhaeghe 1999)
  10. Re: Using [Include] Context (Josh Tiger 1999)
  11. Re: Using [Include] Context (Vince Medina 1999)
  12. Re: Using [Include] Context (Nicolas Verhaeghe 1999)
  13. Re: Using [Include] Context (Bob Minor 1999)
  14. Re: Using [Include] Context (Vince Medina 1999)
  15. Re: Using [Include] Context (Bob Minor 1999)
  16. Re: Using [Include] Context (Kenneth Grome 1999)
  17. Re: Using [Include] Context (Vince Medina 1999)
  18. Re: Using [Include] Context (Bob Minor 1999)
  19. Re: Using [Include] Context (Kenneth Grome 1999)
  20. Re: Using [Include] Context (Vince Medina 1999)
  21. Re: Using [Include] Context (Nicolas Verhaeghe 1999)
  22. Re: Using [Include] Context (Anup Setty 1999)
  23. Re: Using [Include] Context (Vince Medina 1999)
  24. Re: Using [Include] Context (Brian Boegershausen 1999)
  25. Re: Using [Include] Context (Vince Medina 1999)
  26. Re: Using [Include] Context (Bob Minor 1999)
  27. Using [Include] Context (Vince Medina 1999)
The key is in how you interpret the word relative in this context. Relative to the current document, or relative to the root. Webcatalog is expecting the former. On NT, root relative is further confused by the fact that the leading slash in the path actually points to the Webcatalog directory in the scripts directory, instead of the expected web site root. What you need to do is create a document relative path, such as [include file=../include/filename.txt] which will work on all platforms. In fact, in html as well as webdna, using root relative or semi-qualified paths can, and usually will, make your web site non-portable. References such as src=/images/header.gif will lock your web site in the directory structure that it's in now, needing code revision to move the site to a new server that may use different server software or directory structures. Simple answer: where possible, always use ../filepath/ (document relative) file paths instead of /filepath/ (root relative) file paths, whether in your WebDNA or in your HTML.Mike> From: Vince Medina > Reply-To: (WebCatalog Talk) > Date: Thu, 11 Nov 1999 21:52:30 > To: (WebCatalog Talk) > Subject: Using [include] Context > > When using an [include file=/include/filename.txt] > We get a file not found error. > > As I understand the syntax, the path should be relative to virtual root path > where my htdocs dir is. > > For example: If the site is www.test.com then it should include a file > located in http://www.test.com/include/filename.txt > > Is there something I am missing? > > Vince > > > APC Net, Inc. - sales@apcn.net - www.apcn.net > 4471 NW 36 St. #110 - Miami Springs, FL 33166 > > > > ------------------------------------------------------------- > Brought to you by CommuniGate Pro - The Buzz Word Compliant Messaging Server. > To end your Mail problems go to . > > This message is sent to you because you are subscribed to > the mailing list . > To unsubscribe, E-mail to: > To switch to the DIGEST mode, E-mail to > ------------------------------------------------------------- Brought to you by CommuniGate Pro - The Buzz Word Compliant Messaging Server. To end your Mail problems go to .This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Mike_Davis

DOWNLOAD WEBDNA NOW!

Top Articles:

Talk List

The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...

Related Readings:

Re2: frames & carts (1997) Keep away (1997) Grep and <> (2005) [WebDNA] Silly question (2009) inconsistent webcat calculation? (1997) Bannerad Demo (1998) Digest for 09-30-97 (1997) OK, here goes... (1997) Unknown error: OrderNotCreated (1997) TaxTotal Problem (1997) RE: type 2 errors with ssl server (1997) Uniqueness of [cart] (was Number of cars in cart...) (2004) [WebDNA] Triggers not working (2011) The beginning (1997) [WebDNA] unused database fields. . . . (2014) Help! WebCat2 bug (1997) Buying sans cart (1997) Does TCPconnect/TCPsend do multiples? (2000) Signal Raised Error (Part III) (1997) [OT] SSL (2003)