I’m trying to get some text in a layerslider to mimic the formatting/positioning of text in the body area below it (max-width: 1500px; padding: 0 50px; margin: 0 auto;). I have a test page set up at https://centuryhousdev.wpengine.com/test/ . If I edit the inline css for the text block in the inspector, I can get it — just adding those attributes works (see https://capture.dropbox.com/iVxuHIua6ghGkx8s ). But if I add those to the custom css for that layer in the slider (see https://capture.dropbox.com/mb4Lie9GVdUz3z9H — note, this is how I’ve left it / how it is on the test page, currently), the margin: 0 auto; doesn’t seem to come through; the max-width and the padding come through, but not the margin for the centering (see https://capture.dropbox.com/iDpsdH1ikXX6iaeV ).
Anyone ever tried to tackle that issue? Thanks for your consideration ;)
Hey sky19er,
Thank you for your patience, I have found that all LayerSlider elements have this css:
position: static !important;
margin-right: 0 !important;
margin-bottom: 0 !important;
this prevents margin to be used in the way you wish, you will note they are using the !important;
I tried writing some javascript to try to override this but it was not working. I also tested using a HTML LayerSlider element but it also gets the above rules.
It seems like the LayerSlider is designed to place your content exactly were you want it and not use global width for the elements.
I tried searching Google and the LayerSlider support forum but didn’t find anything helpful.
Best regards,
Mike
OK, thanks anyway for trying all those things!
Hi,
Your welcome, if you have any further questions please create a new thread and we will gladly try to help you. Thank you for using Enfold.
Best regards,
Mike