[TYPO3-english] Display navbar outside of typo3
Christopher Torgalson
bedlamhotel at gmail.com
Mon Oct 12 05:59:40 CEST 2009
Hi there,
On Sun, Oct 11, 2009 at 8:19 PM, Ryan Bilesky <rbilesky at hotmail.com> wrote:
>
> I am adding wordpress to my website for blogging and am getting a custom design to match my typo3 site. I want typo3 to generate and display the navbar on my wordpress. How would I go about this, what file(s) do I need to include? What function do I nned to call to actually display the navbar? ect...
Well if you're asking what to do at the Wordpress end, I can't offer
any specifics. But what I've done in the past for similar projects is
the following:
1. Create a page with a TS template like this:
# Create a page with nothing but the menu markup
#
# Disable ALL auto-generated TYPO3 markup:
config.disableAllHeaderCode = 1
# Unset any default PAGE object that may already exist:
page >
# Create a new page template:
page = PAGE
# Add your main navigation to this page:
page.10 < lib.main_navigation
2. Publish the resulting page as a static file using the Admin Panel
(you'll wind up with a page at a url something like
"fileadmin/publish/203.0.html" [you can configure the publish
directory in the install tool])
3. In Wordpress, you could then include and echo out the file's
contents using php.
Done this way, you'd have to re-publish the static page from step 2
whenever the main navigation changed, but with most sites, it's not
often necessary.
--
Christopher Torgalson
http://www.typo3apprentice.com/
More information about the TYPO3-english
mailing list