Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
CSS Class Names being Output in Lowercase when using AddClass #12
Love CsQuery so far :) hey I tested your new DLL v184.108.40.20614 and the nth-child selector now works, but I got a tiny little problem - when using AddClass my css class names are being output in lowercase - although lowercase class names are the norm - being a .NET guy I like to use camel case e.g. MyCssClass please fix. Apart from that I gotta say "GOOD JOOOB!!!" on a really easy to use and fast program!
Yes for example doc("div#Foo > p:nth-child(3)").AddClass("Bar") will output as
(<)div id="Foo" class="main"(>)
Without the parentheses of course :)
Are you trying to select all children except the first and last? You could do this with the ":not" pseudoselector (i think it's a jquery extension), e.g.
You could do it with jQuery/csQuey, e.g.
It may be faster to use C# to extract everything but the first & last children, e.g. using an example I just created as a test from the "TestHtml" document in the CsQuery.Tests project:
added a commit
Jun 21, 2012
Fixed in current push. You can download the compiled dll under "distribution" folder before I update nuget. I may not update for a couple days because there are a ton of changes to the HTML parser that I want to kick around a bit more before making this official, but it's passing all the tests and everything looks good