How can i display the left blocks and header in external files?
basically i want to grab the left blocks, and my header and shove it into an ouside PN PHP script.
would i need to initialize PN to access these? and if so, what is the bare minimum needed to access, say the blocks() function and be able to include header.php without bombing up with errors?
But not too much that it goes and prints out all of PN!
please note that the non-PN page isnt a module, and will never be one, so dont answer with "make it a module" or "use postwrap" or the like. that is not what i am trying to do, and wont work because of path issues.
thanks in advance for any help!
-N30
Watch
GitHub Core
Show your support for Zikula! Sign up at Github account and watch the Core project!
GitHub Modules
- mazdev responded to »Zikula 1.3.3 - Selecting a category in Pages not working« 05:25 PM
- nestormateo responded to »Fillters in Clip« 06:33 AM
- damon responded to »Can the Updated Version Check be Turned Off (Z 1.3)« 03:19 AM
- frw responded to »Bug in the SMTP mail transfer protocol - Port 25 - Zikula 1.2.9« 22. May
- mdee responded to »Short URL questions« 22. May
- mesteele101 responded to »Problem in Database Connection« 21. May
- Herr.Vorragend responded to »Clip Documentation and Doubt« 19. May
Zikula Blog
- Anatomy of Open Source Projects on Mar 07
- Continuous Review on Mar 01
- Not Invented Here on Feb 24
- How to Contribute Your Code at Github on Jan 13
- 10 Steps to Coding-Nirvana: Tips for Successful Module Writing on Nov 12
- Submitting Bug Report Tickets That Get Results on Aug 17
- Cozi Tricks #1: Syntax Highlighting on Aug 07
Login
Displaying blocks and header in external files?
-
**unknown user**
- Rank: Helper
- Registered: Mar 16, 2002
- Last visit: Oct 21, 2009
- Posts: 676
The basics of making a file that wraps PostNuke around it is, first of all it must reside in the PostNuke root (otherwise paths will break), and contain these calls:
// initialise the pnAPI functions used throughout PN
include_once ("includes/pnAPI.php");
include_once ("includes/legacy.php");
pnInit();
// called before any output
include_once("header.php"); // actual Header of PN, with all HEAD tags like Metatags etc, drawn from theme
>>>Page here<<<
// called after all other output
include_once("footer.php"); // Footer and closes BODY/HTML tags.
- Moderated by:
- Support
Users on-line
- 0 users
This list is based on users active over the last 60 minutes.
