WordPress.org

Ready to get started?Download WordPress

Forums

Simple Staff List
Define a CSS Class in Staff Loop (2 posts)

  1. gsbrock
    Member
    Posted 11 months ago #

    It would be amazing to be able to define a class for the staff-members created by [staff_loop] based on an argument or shortcode.

    For example [staff_loop class="group"] would create divs with class="staff-member even group-name". This would make it easier to manipulate groups of entries with pure CSS.

    The specific use-case I'm thinking about is being able to hide/filter staff members by group after the page has loaded, but I can see a few other use-cases for it as well.

    http://wordpress.org/plugins/simple-staff-list/

  2. gsbrock
    Member
    Posted 11 months ago #

    So after poking around there is already some support for this, but it is NOT dynamic.

    [simple-staff-list wrap_class="YOUR TEXT"] will add a "YOUR TEXT" class but you cannot use short codes such as [staff-name-slug], nor is there a short code for the staff group.

    It may be possible to make several short code declarations as a work around:

    [simple-staff-list group="group1" wrap_class="group1"]

    [simple-staff-list group="group2" wrap_class="group2"]

    But I think this may break up the ordering and possibly mess with the page formatting.

Reply

You must log in to post.

About this Plugin

About this Topic

Tags

No tags yet.