- This topic is empty.
Viewing 7 posts - 1 through 7 (of 7 total)
Viewing 7 posts - 1 through 7 (of 7 total)
- The forum ‘CSS’ is closed to new topics and replies.
The forums ran from 2008-2020 and are now closed and viewable here as an archive.
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/
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
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.
CSS:
div.pagination{display: table; margin: 0 auto;}
No effect on IE 6 or 7 though – You could see it as progressive enhancement.
I think you should wrap pagination with div and adjust css for that div.
@koko the pagination is dynamic in size and a set width will have to be given to the div wrapper.
@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.