-
AuthorPosts
-
August 12, 2019 at 10:54 am #1126762
Hi,
What’s the easiest way to make Advanced Layerslider responsive?
Best regards,
HelleAugust 12, 2019 at 8:31 pm #1126962I also would like to know how to do that? Esspecially how to adjust the height in responsive view?
Kind regards Jak
August 13, 2019 at 3:52 am #1127046August 13, 2019 at 9:48 am #1127113August 14, 2019 at 5:21 am #1127470Hi GraphicEyeDK,
Dette er lidt pinligt, er det ikke?
I get a 404 error on that page.
Best regards,
RikardAugust 14, 2019 at 7:57 am #1127505Sorry. Now it should work.
Best regards,
HelleAugust 18, 2019 at 2:59 am #1128570Hi,
Sorry for the late reply, the best solution, in this case, is to create a second slider for mobile devices. You can clone your desktop version and then adjust the canvas size to match mobile, that is to make it taller than wide 425px x 168px or how ever tall you wish it to be.
Then you can make your text and buttons larger and align them on the page as you like.
Then you can use css to hide and show the two sliders depending on the screen size, for example:@media only screen and (min-width: 768px) { #layerslider-1 { display: block !important; } #layerslider-2 { display: none !important; } } @media only screen and (max-width: 767px) { #layerslider-2 { display: block !important; } #layerslider-1 { display: none !important; } }
If you would like help with the css please create the slider and include admin login in the Private Content area so we can examine the sectors and write the css.
Best regards,
MikeAugust 18, 2019 at 7:26 am #1128591Hi,
where do i have to add a class (and what do i have to add) for layerslider?
kind regards Jak
August 18, 2019 at 8:04 am #1128594hi,
i added:
@media only screen and (min-width: 501px) {
#layerslider-1 {
display: block !important;
}
#layerslider-responsive {
display: none !important;
}
}
@media only screen and (max-width: 500px) {
#layerslider-responsive {
display: block !important;
}
#layerslider-1 {
display: none !important;
}
}and to the class of Layerslider:
for responsive slider: layerslider-responsivefor normal view: layerslider-1
but it does not effect it?
kind regards Jak
August 18, 2019 at 1:04 pm #1128644August 18, 2019 at 2:08 pm #1128659Hi,
victoria,thanks!
I added this code:
@media only screen and (min-width: 501px) {
#layerslider-1 {
display: block !important;
}
#layerslider-responsive {
display: none !important;
}
}
@media only screen and (max-width: 500px) {
#layerslider-responsive {
display: block !important;
}
#layerslider-1 {
display: none !important;
}
}
and this to the class of Layerslider:
for responsive slider: layerslider-responsivefor normal view: layerslider-1
seems there is no effect?
kind regards Jak
August 18, 2019 at 5:56 pm #1128678I’m trying and trying, but i won’t work at yet?
Any ideas?kind regards Jak
August 18, 2019 at 7:44 pm #1128687Hi,
I recommend using the auto-generated slider ID’s, for example, the slider that is on your front page now is “#layer_slider_1” so if you add another one to the page it should be “#layer_slider_2”
I understand that your site is live and you won’t want it to look too odd for very long, so I recommend creating your second slider and then add an admin login in the Private Content area, I will add it to your front page and add the css and test for you, if you wish.
Or you could try adding the second slider and try this css code in the General Styling > Quick CSS field or in the WordPress > Customize > Additional CSS field:@media only screen and (min-width: 501px) { #layer_slider_1 { display: block !important; } #layer_slider_2 { display: none !important; } } @media only screen and (max-width: 500px) { #layer_slider_2 { display: block !important; } #layer_slider_1 { display: none !important; } }
I tested this on my localhost and it works correctly using the auto generated ID’s, but you will want to remove the other css added from the above posts.
Then clear your browser cache and check.Best regards,
MikeAugust 18, 2019 at 7:46 pm #1128688Hi Mike,
thanks for your reply on sunday!!!
Should i add #layer_slider_2 or just layer_slider_2 ?
kind regards Jak
August 18, 2019 at 7:55 pm #1128693Hi Mike,
i just saw slider 1 is named in: layerslider>slider settings > appearence>slider class : layerslider-1
Should i rename it, or is there any other field to input the name of the slider?
Should’nt i put the css to the slider field for css?
kind regards Jak
August 18, 2019 at 7:56 pm #1128694Hi,
In the css it is #layer_slider_1 & #layer_slider_2 as above.*side note*
In css the hashtag means ID & a dot means class.
But if you ever add custom classes or ID’s in the elements you would not add the dots & hashtags, I hope I’m not confusing you, if so just ignore this side note :)Best regards,
MikeAugust 18, 2019 at 7:57 pm #1128695where should i add the ID? I’m confused?
kind regards Jak
August 18, 2019 at 7:59 pm #1128696Where can i add: #layer_slider_1 & #layer_slider_2 ?
Not in: layerslider>slider settings > appearence>slider class : layerslider-1 ?
kind regards JakAugust 18, 2019 at 8:08 pm #1128702In layerslider (responsive slider) is written:
Use shortcode:
[layerslider id=”6″]Use PHP function:
<?php layerslider(6) ?>but even when i rename layer_slider_2 to layer_slider_6 the responsive slider is not loaded.
Only in responsive view there is no banner now.kind regards Jak
August 18, 2019 at 8:09 pm #1128703Hi,
You don’t need to add the ID’s to the lyerslider, it is automatically created in the theme, and add the css above, as is, to your Quick CSS in the theme.Best regards,
MikeAugust 18, 2019 at 8:10 pm #1128706Hi Mike,
should i remove layerslider>slider settings > appearence>slider class : layerslider-1 from class?
I followed your instruction, but it is not working?
kind regards
Jak
August 18, 2019 at 8:17 pm #1128710August 18, 2019 at 8:26 pm #1128715Hi Mike,
works great!
Many many thanks!!!
kind regards Jak
August 18, 2019 at 8:35 pm #1128721Hi,
Well done :)
Glad we were able to help, we will close this now. Thank you for using Enfold.For your information, you can take a look at Enfold documentation here
For any other questions or issues, feel free to start new threads in the Enfold forum and we will gladly try to help you :)Best regards,
Mike -
AuthorPosts
- You must be logged in to reply to this topic.