I am trying to do something I am unsure is possible and need a general direction. I have a WordPress 3.31 multi-site set up. I have several custom roles set up. Student, Teacher1, Teacher2, Teacher3, Family and Friends.
I also have several custom post types set up. The Teacher custom post type is what I am concerned with.
In the very near future we are going to have to add about 3000 blogs to this system. I would like the name of the custom post type to be the name of the person in the teacher role for that blog – automatically. There can be up to three teachers per blog.
So I am thinking somehow query the wp_usermeta for teacher role and then display the teacher’s name. in the custom post set up (below) It would have to loop up to three times since Students may have several teachers. Anyone out there have any idea if this is possible and a general direction?
I.E.
register_post_type( 'journal_teacher',
array(
'labels' => array(
'name' => __(query-here-for-teacher-role) ),...
If you are thinking in turning WordPress into a LMS system I strongly recommend you using Courseware, http://coursewa.re/. It will help you a lot.
I have a custom post type include I use. That roughly includes something like this:
You could likely create something for the $types array that would help you accomplish what you need.
I’ve modified the $types array for you – if you need to adjust it hopefully you understand how to from this. If not I’ll probably need more information on it.