• Resolved twowheeler

    (@twowheeler)


    Here is a start on adding categories to the opportunities. It is simple and crude but seems to do the job for basic categorization.

    This is a patch against the file wired-impact-volunteer-management/frontend/class-public.php. It adds a “cat” attribute to the shortcodes, so you can use something like: [one_time_volunteer_opps cat=”ushers”] so that the output is limited to opportunities in the category “ushers”. If “cat” is missing all opportunities are shown.

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Wired Impact

    (@wiredimpact)

    Thanks a ton for sharing @twowheeler. If you want to submit changes or updates to the plugin we’d recommend you do it by using a pull request to the plugin’s repo at https://github.com/wiredimpact/wired-impact-volunteer-management.

    The biggest issue I see right now with the code would be that the patch uses the built-in categories taxonomy instead of a custom taxonomy. I’m not 100% sure about this, but I think the categories would then be used on both the blog and the volunteer opportunities. This most likely wouldn’t work for many nonprofits since they would want the categories to be different based on the type of content. I’d recommend using an entirely new taxonomy via register_taxonomy().

    I’d love to hear what you think and thanks again for sharing the patch. We really appreciate it.

    Jonathan

    Plugin Author Wired Impact

    (@wiredimpact)

    Since it’s been a little while I’m gong to mark this ticket as resolved. Don’t hesitate to reach out again in the future if you want to discuss how to build categorization into the plugin. Thanks again.

    Jonathan

    I can’t code but would love to see categories in this plugin, don’t really care if I have to mess up the website category structure to do so…

    Plugin Author Wired Impact

    (@wiredimpact)

    Thanks for the note @webhexnl. Categories have been requested a few times and are definitely something that we’re considering adding in the future.

    Jonathan

    Thread Starter twowheeler

    (@twowheeler)

    My apologies – I have been super busy and haven’t found time to come back to this. Yes, the submitted code is simple and just adds opportunities to the built-in categories rather than creating a custom taxonomy. I am not going to tackle that more sophisticated version but I hope you will do so in the future. Meanwhile the quick and dirty approach works for me. Thanks.

    Plugin Author Wired Impact

    (@wiredimpact)

    That makes sense to me. Thanks a lot @twowheeler.

    Jonathan

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Categories for volunteer opportunities’ is closed to new replies.