View Single Post
Old 06-18-2017, 12:59 PM   #6
Turtle91
A Hairy Wizard
Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.
 
Turtle91's Avatar
 
Posts: 3,361
Karma: 20212223
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 15/11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
There are solutions to vertical spacing...I use them all the time for my title and dedication page. It relies on the "display:table" and "display:table-cell" elements without actually using a table. It allows the element - in this case the <div> - to behave like a <td> and thus use the "Verticle-align" property. It works great on some devices/apps - and IMO should be supported by all compliant devices - but you'll have to test it to make sure.

Here is what I use:
Code:
CSS
div.v-ctr     {display:table; position:fixed; 
               height:100%; width:100%; 
               padding:0; margin:0; text-indent:0}

div.v-ctr div {display:table-cell; vertical-align:middle;
               padding:0; margin:0}

HTML
<body>
  <div class="v-ctr">
    <div>
      <p>Centered vertically</p>
    </div>
  </div>
</body>
Hope that helps!

Cheers,

Last edited by Turtle91; 06-18-2017 at 01:02 PM.
Turtle91 is offline   Reply With Quote