Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I'm working on a real-estate site where I need to create a profile for each agent, the initial view when you click on view agents would be to list them alphabetically, ideally from a dropdown you could select a region to view all the agents from that region, or chose a language to view all the agents who speak a given language.

My thinking is Agent would be a custom post type, region and language would be a taxonomy.

The listing of agents would then be created by showing many posts, just only showing limited details, then when clicked act as a single post, with more details shown?

Does this seem like the best way to go about this?

Thanks

share|improve this question
add comment

1 Answer

up vote 6 down vote accepted

That Sounds about right, I'm just about to finish similar project with the same base (post type, taxonomies) structure, so here are a few notes to get you going:

  • To enable your "view agents" make sure when you register agents post type that you set has_archive to true or use string as archive slug which will make your life much easier.
  • When registering custom taxonomies make sure to set rewrite to true.
  • Create a custom template taxonomy-{taxonomy}.php for each of your custom taxonomies (even if they both show the same thing, trust me on this one) this will save you a lot of time.
  • On your "view agents" template file (archive-agents.php) Use wp_dropdown_categories function to generate your region and language dropdowns.
  • And last create your single-agents.php template file to display the full information of the agent.
share|improve this answer
    
Cannot argue with the points you have made there. I remember my first custom post type set-up. Its very confusing at first but after you've done a few its easy peasy :) –  Brady Apr 13 '11 at 10:14
    
Thanks should be an interesting weekend ahead, if anyone else has any other tips they're greatly appreciated. –  Chuck Apr 13 '11 at 13:31
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.