macromedia.contribute.general_discussion
[Top] [All Lists]

Re: Template Headaches (PHP includes & links getting rewritten)

Subject: Re: Template Headaches (PHP includes & links getting rewritten)
From: "Connor Doyle" <webforumsuser@xxxxxxxxxxxxxx>
Date: Sun, 20 Jul 2008 14:31:09 +0000 (UTC)
Newsgroups: macromedia.contribute.general_discussion

glockops:

 I am finishing up my first deployment of Adobe Contribute CMS for one of my 
clients, and I was having the same problem with PHP require().  I found the 
following article on the Adobe KB that contains our solution:

 Article: "Document relative paths pointing to items located in the Templates 
folders are rewritten in new pages created from templates"
 http://kb.adobe.com/selfservice/viewContent.do?externalId=52195a7  

 In the .dwt, you must surround the paths in question with a proprietary syntax 
which causes them to be treated as literals instead of Template Parameters, 
like so:

 <?php include("foo.php");  ?>

 becomes:

 <?php include("@@('foo.php')@@"); ?>

 This technique also works for any other type of relative paths to external 
resources such as images, scripts, stylesheets, etc.
 All the best,
 --
 Connor Doyle
 One Orange Software


<Prev in Thread] Current Thread [Next in Thread>