Centering the entire webpage

This public forum is for user-to-user discussions of PHPMaker. Note that this is not support forum.
Post Reply
napiedra
User
Posts: 142

Centering the entire webpage

Post by napiedra »

I would like to center all pages including the login and the menu in addition to all views. How can I accomplish that?


mobhar
User
Posts: 11703

Post by mobhar »

Just inspect the element id from your browser, and use jQuery code from "Client Scripts" section to customize its stylesheet.


digitalphotoworld
User
Posts: 416
Location: Nürnberg/Germany

Post by digitalphotoworld »

Don't use jQuery for such a task!

To center the entire webpage, just add 2 lines of css. The main-class for each PHPMaker project is ewLayout. One solution is to add a custom stylesheet with the modification:

.ewLayout {
margin: 0px auto;
width: 90%;
}

With margin: 0px auto, the DIV will centered. But that this can work you need a width for your DIV-Element (the main-content of the page). In the example I used 90%, but you can also use something like 960px etc.


napiedra
User
Posts: 142

Post by napiedra »

Thanks, both worked although I liked the editing of CSS.


Post Reply