WebsiteBaker Logo
  • *
  • Templates
  • Help
  • Add-ons
  • Download
  • Home
*
Welcome, Guest. Please login or register.

Login with username, password and session length
 

News


WebsiteBaker 2.13.8 is now available!


R.I.P Dietmar (luisehahne) and thank you for all your valuable work for WB
https://forum.websitebaker.org/index.php/topic,32355.0.html


* Support WebsiteBaker

Your donations will help to:

  • Pay for our dedicated server
  • Pay for domain registration
  • and much more!

You can donate by clicking on the button below.


  • Home
  • Help
  • Search
  • Login
  • Register

  • WebsiteBaker Community Forum »
  • WebsiteBaker Support (2.8.x) »
  • Templates, Menus & Design »
  • Design for additional page content
  • Print
Pages: [1]   Go Down

Author Topic: Design for additional page content  (Read 6326 times)

Offline richwingerter

  • Posts: 69
Design for additional page content
« on: October 26, 2016, 11:44:40 PM »
I have a question about design. I'd like to put some standard content in a second column.

I think I should be able to do this by adding a <div> in the index.php code for my template next to the code for presenting page content. The existing <div> is:

Code: [Select]
<div>
   <?php echo $page_contentMain; ?>
</div>

It has a class, where I make it the left column.

I added a second column, where I put the login box (like this):

Code: [Select]
<div>
   [[LoginBox]]
</div>

This also has a class that makes it the right column. The login box shows up and works.

I'd like to add standard code after the login box, but I don't want to define it in the template. I'd like to pick it up from a table and display it here.

My design question is: what's the best way to store and get this HTML code? What I'm looking for is something analogous to what WB does with $page_contentMain.

It would help if I could see the definitions of ob_start(), page_content(), and ob_get_clean(), but I don't see them in the files I have.

Does anyone have any advice on how to do this? Thanks for any assistance!

I'm on WB 2.8.3+SP7 (r1646) and MySQL 5.5.52-38.3-log (with charset UTF-8 Unicode).
Logged

Offline Ruud

  • Posts: 3671
  • Gender: Male
  • Do not use PM for help! Please use the forum!
    • Dev4Me - Professional WebsiteBaker Development
Re: Design for additional page content
« Reply #1 on: October 26, 2016, 11:52:02 PM »
have a look here:
http://wbhelp.org/tips-and-tricks/2014/multiple-columns-in-a-template/

Maybe it helps a bit.
Logged
Dev4me - WebsiteBaker modules - WBhelp.org

Offline richwingerter

  • Posts: 69
Re: Design for additional page content
« Reply #2 on: October 27, 2016, 01:42:53 AM »
I did get information on ob_get_clean() and similar functions from http://php.net/manual/en/function.ob-get-clean.php. That should help.
Logged

Offline richwingerter

  • Posts: 69
Re: Design for additional page content
« Reply #3 on: October 27, 2016, 01:43:53 AM »
Thanks for the link, Ruud. I think that will help!
Logged

  • Print
Pages: [1]   Go Up
  • WebsiteBaker Community Forum »
  • WebsiteBaker Support (2.8.x) »
  • Templates, Menus & Design »
  • Design for additional page content
 

  • SMF 2.0.19 | SMF © 2017, Simple Machines
  • XHTML
  • RSS
  • WAP2