Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Custom class for last item. #9

Open
vierkantemeter opened this issue Jun 12, 2011 · 1 comment
Open

Custom class for last item. #9

vierkantemeter opened this issue Jun 12, 2011 · 1 comment

Comments

@vierkantemeter
Copy link

Hi, I'm using this great add-on for a html sitemap on my website. I would like to know if it would be possible to give the last item in a list a custom class, like 'lastItem', so I could style it different. Does anyone know how I could achieve this? (and maybe the first item as well..?)

Thanks for any help!
Michelle

@yogoo
Copy link
Contributor

yogoo commented Mar 28, 2012

If you want to style them I assume you're dealing with html. In this case, the pseudo class :first-child and :last-child would do. You can use a polyfill such as Selectivizr to use :last-child in IE6, 7, 8.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants