Tagged: header, LayerSlider
-
AuthorPosts
-
May 19, 2015 at 10:33 am #446302
Hi
I’m sorry to ask a question that has been asked in the forum, but I find no answerAs the title says, I’m trying to include a layerSlider in the header
To do so,
I’ve installed the layerSlider WP plugin and create a new slider (ID 5)
I’ve copied the helper-main-menu.php in my child theme (in includes/helper-main-menu.php)I’ve add below this code
/* * Hook that can be used for plugins and theme extension/*
(line 149)
These line
<div id="sliderheader"><?php echo do_shortcode("[av_layerslider id='5']"); ?> </div>
But it display an empty and blank space (as the slider #5 exists)<div id="sliderheader"><?php echo do_shortcode("[layerslider id='5']"); ?> </div>
But it display the shorcode in itself as e text (i.e [layerslider id=’5′] , and nothing esleWhat should I do to display the slider ?
Many thanks
May 20, 2015 at 4:37 pm #447248Hey Ikyo!
I don’t think you’ll be able to use do_shortcode with the LayerSlider.
And the reason the shortcode is displaying is because you need to use
[av_layerslider id='5']
.Also, if you have the LayerSlider installed as a plugin then it would be best to deactivate that. We already include it in the theme files.
Best regards,
Elliott- This reply was modified 9 years, 6 months ago by Elliott.
May 21, 2015 at 10:11 am #447651Thanks for your Answer Elliott
The only code you gave me doesn’t works in the headerBut whenever i’m adding the following code
<div id="slideraccueil"><?php echo do_shortcode("[av_layerslider id='5']"); ?> </div>
in includes/helper-main-menu.php
AND
`[av_layerslider id=’5′].’ in a page
It’s workingThe problem is I want the slider in every header of every page of the site…and it will be meaningless if I add it manually in each part of my site
What should I do ?
Thanks for your precious help and your powerful supportThanks !
- This reply was modified 9 years, 6 months ago by Ikyo.
May 22, 2015 at 5:21 pm #448483Hi!
Yeah I don’t think that’s going to work. It’s probably going to take a lot of layout changes. It would be best to hire a freelancer to help you out with this customization.
Regards,
ElliottMay 22, 2015 at 5:24 pm #448487Thank you for your precious help Elliott
I’ll follow your advice
Have a nice week-end -
AuthorPosts
- The topic ‘Insert layerslider in header php’ is closed to new replies.