Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Adding a new component
#2
gioacchinomauri Wrote:I'm using the default installation of GetSimple without plugins and i want another "sidebar" component below the original one. How can i add this new component in the page ?
If you open up the file "sidebar.php" in GS' default theme "Innovation", you'll find the following code at line 38:

Code:
<div class="section">
    <?php get_component('sidebar');  ?>
div>

The code which actually includes the component named "sidebar" is

Code:
<?php get_component('sidebar');  ?>

So, if you named your component "sidebar2", just copy and paste the line where you want it to appear in the markup and replace "sidebar" with "sidebar2". Place HTML markup around your component as you need.

Besides, right above the entry field in the backend where you input your component contents, you can find the exact line of code you'll need for inclusion in the template. GS automagically creates that line with your chosen component name.

Hope that helps!
Reply


Messages In This Thread
Adding a new component - by gioacchinomauri - 2011-04-10, 23:51:34
Adding a new component - by polyfragmented - 2011-04-11, 01:37:23



Users browsing this thread: 2 Guest(s)