Community Forums › Forums › Archived Forums › Design Tips and Tricks › Can I insert a slideshow above blog posts in Bee Crafty Theme?
Tagged: bee crafty, blog page template, image slider
- This topic has 21 replies, 2 voices, and was last updated 11 years, 4 months ago by Brad Dalton.
-
AuthorPosts
-
July 16, 2013 at 1:37 pm #50986jchickMember
Hi,
http://chocolatemakingfun.com
I'm using the bee crafty theme here: http://chocolatemakingfun.com. I want to be able to add some things to the homepage. The homepage is using the blog template. IIs there a way for me to add an image slider above the blog posts? The idea I'm trying to duplicate is here: http://mycakeschool.com.
Any help is greatly appreciated.
JohnJuly 16, 2013 at 1:49 pm #50988Brad DaltonParticipantHey John
Yes you can create a new widget and use the Genesis Responsive Slider or hook in another slider directly before your blog posts are listed on the home page only.
Please copy one of these PHP code snippets from the view raw link and paste it at the end of your child themes functions.php files using a text editor like Notepad++
Or install the Easing slider plugin and add this code to your child themes functions.php file.
You can also change the slider position by changing the hook.
July 16, 2013 at 2:20 pm #50989jchickMemberThanks for this. I'll see if I can get this to work. Much appreciated!
July 16, 2013 at 2:24 pm #50990Brad DaltonParticipantNo worries John.
I know Guthub Gists are having a few problems at the moment hosting the code snippets so the view raw link may not work when trying to copy the code.
July 16, 2013 at 6:29 pm #51065jchickMemberI bought easing slider and added the code to the functions.php file and created a slideshow but it's not showing up on my homepage.
July 16, 2013 at 6:32 pm #51066jchickMemberShould I be using the blog page template for the homepage or the default template. Bee Crafty had a default homepage functionality that I didn't want to use and someone instructed me on how to disable the functionality by renaming home.php to oldhome.php. Could this be why I don't see the slider on the homepage?
July 16, 2013 at 6:55 pm #51073Brad DaltonParticipantWhich code snippet did you use?
Its probably because of the conditional tag.
Try changing
is_home()
to
is_front_page()
You can also change the hook.
July 16, 2013 at 7:38 pm #51077jchickMemberI used this snippet:
`add_action('genesis_before_loop', 'display_slider_before_posts_home');
/**
* @author Brad Dalton - WP Sites
* @example http://wpsites.net/web-design/image-slider-home-page-only/
*/
function display_slider_before_posts_home() {
if ( is_front_page() && function_exists('easing_slider') ) {
easing_slider();}
}
That's not working for some reason. Is it because I'm using the blog template for the homepage?
July 17, 2013 at 4:18 am #51108Brad DaltonParticipantThe name of the tag for the slider maybe different as i wrote this code for the Lite version and not the premium version.
I assume you've create a slide show and added images to it?
July 17, 2013 at 10:00 am #51151jchickMemberYes, I've created a slideshow and added images.
July 17, 2013 at 11:35 am #51173Brad DaltonParticipantTry using page-id-16
if ( is_page( 16 ) && function_exists('easing_slider') ) {
Did you change the hook?
add_action('genesis_before_content', 'display_slider_before_posts_home');
July 19, 2013 at 11:02 am #51462jchickMemberHi Brad,
That didn't work, either. I really appreciate your help with this.
JohnJuly 19, 2013 at 11:04 am #51463jchickMemberHere's a link to a screenshot of what I did in the editor:
http://websitesbycreation.com/beecraftycode.pngJuly 19, 2013 at 12:37 pm #51469Brad DaltonParticipantHi John
I tested the code and it works.
Can you link to the page please. Is it a page or post?
Can you also send me a copy of the easing slider plugin that you bought. [email protected]
Also try adding some single quotes around the page i.d
'16'
July 19, 2013 at 12:46 pm #51470jchickMemberStill no luck. Screenshot attached.
http://websitesbycreation.com/beecrafty2.pngJuly 19, 2013 at 1:07 pm #51471Brad DaltonParticipantDid you check the name of the function in the documents for the Pro version?
I don't have access to these however i think the problem is the Pro version uses a different name for the function.
Please check this and reply here with the PHP code which they supply for installation of the Pro version.
As previously stated, the code above works for the Lite version only.
July 19, 2013 at 3:47 pm #51510jchickMemberI'm not sure about the php code. All I have is this documentation from the easingslider pro website:
If you wish to display a slideshow within your theme, you must use the PHP function. Shortcodes are not supported within theme files. Using the PHP function is easy. Simply insert the code below into the theme file you wish to display a slideshow in. Again, don’t forget to replace the “1″ with the ID of the slideshow you wish to display.
<?php if ( function_exists('easingsliderpro') ) { easingsliderpro( 1 ); } ?>
I found it on this page: http://easingslider.com/docs/displaying-slideshows/
July 19, 2013 at 4:35 pm #51516Brad DaltonParticipantThat's why it didn't work because the function name is different for the 2 slider versions
Tested this code and it works:
Otherwise please change the conditional tag if needed.
July 19, 2013 at 4:50 pm #51521jchickMemberThat worked! Thanks! Now, is there any way to get the sidebar on my homepage?
July 19, 2013 at 5:00 pm #51524Brad DaltonParticipantStart another thread please and marked this one as resolved. It will get answered faster that way.
Try the Genesis Layout Extra plugin
-
AuthorPosts
- The forum ‘Design Tips and Tricks’ is closed to new topics and replies.