[SOLVED] How to center the slider
Permalink Browser Info Environment
Hi,
I tried to center the slider overlay on my page, through the properties but the slider disapeared each time.
How can I do that?
Thanks.
I tried to center the slider overlay on my page, through the properties but the slider disapeared each time.
How can I do that?
Thanks.
Type: | Discussion |
---|---|
Status: | New |
You're right. It seems for now that the only way to place the Slider Overlay centered is by using layout.
Thanks for this solution.
Thanks for this solution.
For my gallery I have a mixture of landscape and portrait pictures, I was hoping to align these centrally.I want to use a height constraint and allow the widths of the image to vary but still maintain central alignment. Am I right in thinking this will not be possible using the 3 column workaround, as all the images will still be aligned left in the central column?
thanks
RS
thanks
RS
It would be quite fiddly to get a solution around that. Unfortunately HTML & CSS doesn't have any built-in support for vertically aligned elements. But there are a couple workarounds available:
1) Place the Slider Overlay inside a table cell and vertically align that; or
2) Apply a CSS hack to obtain vertical alignment (but you have to hard-code the height of the element/s into your stylesheet, so it's not very flexible. It's quite messy and easily breaks in an environment like C5 where the content can change so quickly.
Hope this helps.
JB
1) Place the Slider Overlay inside a table cell and vertically align that; or
2) Apply a CSS hack to obtain vertical alignment (but you have to hard-code the height of the element/s into your stylesheet, so it's not very flexible. It's quite messy and easily breaks in an environment like C5 where the content can change so quickly.
Hope this helps.
JB
Thanks for the quick reply, I'll give the table a go and see what happens..
Thanks
RS
Thanks
RS
It is a bit strange that the whole slider simply disappears. I've been able to replicate this as well. The only way to center align a DIV tag is using the CSS tag "margin". But implementing this would be fiddly and prone to conflicts with site themes.
So the easiest workaround is to use the "layout" feature in the core of C5. Simply create 3 columns and 1 row. Place the Slider Overlay into the middle column and adjust the width on the left and right accordingly. Not an elegant solution, but it will work.
Hope this helps.
JB