I'm building off the BFNav child theme and the area inner top that houses the search bar I'd like to put a slider in there that shows on the home page. Putting the short code in the functions.php file where the php for the search box is at obviously won't work. I tried to use an outside slider wp-carousel plugin in that area but it doesn't seem to like the theme. Any ideas?
Slider Template Tag
(5 posts) (3 voices)-
Posted 1 year ago #
-
you can execute shortcodes from php like this:
echo do_shortcode('[bfslider name="slider" type="page"]');Posted 1 year ago # -
Thank you!
Posted 1 year ago # -
for anyone else who was looking to do this
<?php if (is_front_page()) { echo do_shortcode('[bfthumbs numposts="5" width="153" height="120" numcols="5" marginright="20" text="false" cufon="false" numwords="10" class="smallheading"]');
} else {
echo 'whatever other element goes here';
}
?>
in functions.phpPosted 1 year ago #
Reply
You must log in to post.