WebsiteBaker Community Forum (upd)

WebsiteBaker Support (2.8.x) => Templates, Menus & Design => Topic started by: Tinke on November 23, 2009, 12:23:04 AM

Title: [wblinkXX] to my template
Post by: Tinke on November 23, 2009, 12:23:04 AM
Hello,
I have small problem.
I have a site which has lots of links to website baker pages. And many links are outside WebsiteBaker content -area.
Is it possible to [wblink-page-id] style link added to my tempalte file.
example: <a href="[wblink3]">My Link</a>
Note. This link is not a WYSIWYG editor page. This link are my template footer.   :-)
Title: Re: [wblinkXX] to my template
Post by: DarkViper on November 23, 2009, 03:51:33 AM
It is possibel to do in a inofficial way.

You must buffer your footer and do a extra parsing


<?php
  ob_start
();
?>

...
place here all your HTML and PHP of your footer (including your [wblinkxxx] parts)
...
<?php
  $output 
ob_get_contents();
  
ob_end_clean();
  
$wb->preprocess($output);
  echo 
$output;
?>


I've not testet yet... but it should work. (without any guaranty) 8-)
Title: Re: [wblinkXX] to my template
Post by: Tinke on November 24, 2009, 10:23:05 AM
WOOW!  :-D
This works very vell.
Thank you very much!   :-D

--
Tinke