Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
components on selected pages
#1
Something like this:

<?php get_component('sidebar'); ?- show on page "home, other">

<?php get_component('news'); ?- show on page "page2, page3">

and will be nice to see editor there (tiny mce)
kotos.net - webdesign / dtp / graphics / photography
Reply
#2
Components are made to be pieces of templates that you can edit. So if you want your pages to be marked up different you can use multiple template files in your theme.

You could also take a look at my function for per page components. Then you can have the same template file, which will load a certain component, but also create components for certain selected pages that replace the standard one without having to do weird things with your theme.

There has been talk about using an editor for components, but also against it. This because components are made to be this closely related to the template files and an editor will disable the possibility of using PHP.

More talk about this can be found in these topics: additional contents sections and Component Sorting.
“Don’t forget the important ˚ (not °) on the a,” says the Unicode lover.
Help us test a key change for the core! ¶ Problems with GetSimple? Be sure to enable debug mode!
Reply




Users browsing this thread: 1 Guest(s)