Group authors in alphabetical index
-
Hi,
I know this is a duplicate of this request but I can’t comment there because it has been closed to new replies.
I basically have the same request but I also want to suggest a possible solution:
Right now, your plugin outputs something like this:
<div class="user with-name user-137 with-biography bio-length--1"> <a href="author link" title="Firstname Lastname (1 post)"> <span class="name"><strong>Firstname Lastname (1)</strong> </span> </a> <div class="biography"> <p>Author Bio</p> </div> </div>
Since your plugin is already able to sort the users by the first letter of their last name, wouldn’t it also be possible to include the first letter of the last name as a class inside the div like so?:
<div class="letter-l user with-name user-137 with-biography bio-length--1"> <a href="author link" title="Firstname Lastname (1 post)"> <span class="name"><strong>Firstname Lastname (1)</strong> </span> </a> <div class="biography"> <p>Author Bio</p> </div> </div>
As you can see here, letter-l stands for the first letter of the last name, which in this case is the letter L.
If that would be included in the class of the div or the anchor tag or the span or wherever you like, I could build an alphabetical index in pure CSS and offer the code here for others to use.
- The topic ‘Group authors in alphabetical index’ is closed to new replies.