I don’t mind using PHP or just html/css shortcode on my page whichever one works better…
Plugin Author
Gabor
(@nextendweb_gabor)
Hi! If you want to make your slider to have the width of the screen, you will have to put the slider’s shortcode into your theme. You can read about this in here:
http://www.nextendweb.com/wiki/smart-slider-documentation/frequently-asked-questions/#fullwidthwp
The code you should look for is this (it will be probably in your theme’s header.php file):
</header>
and put your slider’s code right under it:
<?php
if(is_home() || is_front_page()){
echo do_shortcode('[smartslider2 slider="5"]');
}
?>
or just this, if you want it on all of your pages:
<?php echo do_shortcode('[smartslider2 slider="5"]'); ?>
Actually, I already read the FAQ and tried that PHP code in my header, but its not full width and it appears on top of my banner and navigation bar.
<br />
<?php<br />
if(is_home() || is_front_page()){<br />
echo do_shortcode('[smartslider2 slider="5"]');<br />
}<br />
?><br />
For some weirder reason, it enlarges my banner and menu by a whole lot and dearranges my current layout.
Maybe because I am putting the code in the wrong place in the header.php? I already placed it under site navigation code though.
Nevermind, I placed it below the </header> and it works now. Thanks!
I just placed it in the wrong place. I added a
<div style="margin-top: -22px">
above since there is extra margin above the slider.