Jump to content

Archived

This topic is now archived and is closed to further replies.

outtareach

Center not working

Recommended Posts

outtareach    3
outtareach

I used yout class .center on a media box and it isnt centering.  I also tried to add the class "middle" and put "margin-left: auto" and "margin-right:auto" which no changed.  Also how com adding float in the custom css doesnt seem to work?  Seems like certain rules are not working in the custom css section of dms.

Share this post


Link to post
Share on other sites
Danny    1,327
Danny

HI,

 

That won't work correct, I need to update the docs to inform users of this. Basically, when you add a class to the Styling Classes field, it adds that classes CSS to the section itself and not the content inside the section.

Lets say you have add HTML in a MediaBox to create add some text, for example.

 

<h1>This is a header in a MediaBox</h1>

 

If you want to center this, add the class to the HTML, for example.

 

<h1 class="center">This is a header in a MediaBox</h1>

 

http://cl.ly/image/1P1T2g3h1y3V

 

So if you want to add classes to specific content, you will need to add the class to that element and not the styling classes, as this is for the section itself.

 

The Styling classes come into use and are powerful if you want to add background colors to your sections, see our documentation here - http://docs.pagelines.com/tutorials/section-area-styling


Please search our forums, before posting!

Share this post


Link to post
Share on other sites
outtareach    3
outtareach

Thank so if I create a media box and in styling classes give it a name of "middle" then put custom css in for .middle it should change the css for that section correct?  If I put something else in that mediabox say html and give it the same class then it should still work correct?  And if I add a class to my html and add the code in "custom css" I should get the changes right?  I am doing that and wasnt getting changes.  I will attempt again but this seems pretty straightforward.  Thanks

Share this post


Link to post
Share on other sites

×