Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS Help: Centering WordPress Pagination

  • This topic is empty.
Viewing 7 posts - 1 through 7 (of 7 total)
  • Author
    Posts
  • #30813
    Anonymous
    Inactive

    I am working on moving my website onto wordpress. I’d like to have the pagination centred rather than aligned to the left.
    How do I do this?

    See my code here:
    http://www.aarongmoore.com/test/

    #67970
    cybershot
    Participant

    well, do you know any css? You can use css to center the text. It depends on how you wrote your blog or how you set it up. You can view the source code of the page and see what class has been given to the pagination and then in your stylesheet you add that class and center the text

    #67981
    Anonymous
    Inactive

    I used the pagination from: http://design.sparklette.net/teaches/how-to-add-wordpress-pagination-without-a-plugin/

    I tried adding “text-align: center” but that seemed to have no effect.

    #67982
    jamygolden
    Member

    CSS:

    div.pagination{display: table; margin: 0 auto;}

    No effect on IE 6 or 7 though – You could see it as progressive enhancement.

    #67984
    koko
    Member

    I think you should wrap pagination with div and adjust css for that div.

    #68023
    jamygolden
    Member

    @koko the pagination is dynamic in size and a set width will have to be given to the div wrapper.

    #137820
    jdfx
    Member

    @jamy_za Thank you!! Seems like such a simple thing to do but the dynamic width poses a problem, display:table works great, neat little trick.

Viewing 7 posts - 1 through 7 (of 7 total)
  • The forum ‘CSS’ is closed to new topics and replies.