Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Components specific to the page - How?
#10
I am still not getting this right. I have a site with banner type header images across the tops of the pages. The homepage has a slideshow of images and the slideshow is the default unless a specific static image is assigned to a page. I have put the slideshow and the static images in components which I am calling with the following:
PHP Code:
<div class="banner">
                <?
php  if (get_component('banner-'.get_page_slug(false)))
                                {
get_component('banner-'.get_page_slug(false));}
                        else {
get_component('slideshow');}    ?>
            </div> 
I get the slideshow alright on the homepage, but where I have a page specific image in a component I get both the static image and the slideshow below it displayed on the page.

Help appreciated.
Reply


Messages In This Thread
RE: Components specific to the page - How? - by Timbow - 2013-03-07, 23:53:04



Users browsing this thread: 2 Guest(s)