We are transitioning over to a new forum platform. Please post new issues there. Existing threads will be dealt with here unless you choose to move them over. Visit the new forum
Using php include on a Perch page, to link another page containing perch content
Forgive the long winded title. Basically I've been tasked with editing a site that was built by a previous employee, and the setup is that the navigation, footer, sidebar etc... are all in separate php files so that you can use PHP include to bring the same footer into all pages etc...
The problem I have, is that if you were to add a Perch tag into one of these included pages, the only way to have them show up in the perch backend, is to ensure you have a link to the perch/runtime.php. Which works fine to get in and add your content.
HOWEVER! As I'm sure you've already realised, this means that both the main page (say index.php) and it's included footer.php will both make reference to perch/runtime.php, which looks to break the page and as a result nothing loads.
Is there a way around this that doesn't involve hard coding the content into every single page? I am relatively new to Perch so forgive me if I'm going about it in the wrong way :)
Want to reply to this thread?Login with Perch