Support

Home Forums Event Espresso Premium How to add a list of all staff members

How to add a list of all staff members

Posted: February 18, 2014 at 10:16 am


Jodi Buckingham

February 18, 2014 at 10:16 am

I have version 3.1.36 installed on WP 3.8.1 with the Tempera theme. I would like to add a page of instructors that would link to all events that the instructors teach. I guess I would need to pass the staff ID as a param or something. Is there an easy way to do this or do I need to do some customizations here?


Dean

February 19, 2014 at 1:58 am

Hi Jodi,

That is something we don’t have, the shortcodes can list staff attached to a specific event, but not actually link to what events they are attached to.

I would say you would need some minor customisation.

What I would do is add a link/s on the staff page which goes to another page that has a special page template assigned to it.

This link will have a url query, for example, if the page with the template is http://www.myexample.com/staff-events, the link would be http://www.myexample.com/staff-events?staff=1, where 1 is the staff ID

Then the page with the template would have a custom page template which echoed the EVENT_LIST shortcode, but that grabs the URL query

something like

<?php

$x = $_GET['staff'];
echo do_shortcode('[EVENT_LIST staff_id="' . $x . '"]');

?>

Making a page template is pretty easy, I just copied the themes page.php and renamed it and added a little bit of code – see here http://codex.wordpress.org/Page_Templates – then assigned the template to the page where I want the events to be shown.

I hope that makes some sense.


Jodi Buckingham

February 19, 2014 at 12:46 pm

Totally makes sense and I’ve something to that effect and it works great…thanks for your input!


Dean

February 20, 2014 at 4:36 am

No problem!

The support post ‘How to add a list of all staff members’ is closed to new replies.

Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.

Event Espresso