Support » Fixing WordPress » Marking Businesses for sale with custom taxonimies

  • Hi,

    I’m making a business listing directory.

    I created a custom taxonomy called [business_status] with 2 options ‘Businesses For Sale’ and ‘Businesses Sold’.

    I then created another custom taxonomy called [business_category]
    that shows whether it’s ‘wholesale’ or ‘retail’ etc.

    I want to show [business_category] categories in a list but only those maked as ‘Businesses For Sale’ in [business_status].

    To list the [business_category] I can simply use this:

    $taxonomy     = 'business_category';
    $orderby      = 'name';
    $show_count   = 0;      // 1 for yes, 0 for no
    $pad_counts   = 0;      // 1 for yes, 0 for no
    $hierarchical = 1;      // 1 for yes, 0 for no
    $title        = '';
    $args = array(
      'taxonomy'     => $taxonomy,
      'orderby'      => $orderby,
      'show_count'   => $show_count,
      'pad_counts'   => $pad_counts,
      'hierarchical' => $hierarchical,
      'title_li'     => $title
    <?php wp_list_categories( $args ); ?>

    But how do you limit this list to only show the businesses that are for sale?

    I would appreciate any help. Thanks.

Viewing 2 replies - 1 through 2 (of 2 total)
  • I’m starting to think this kind of website is completely impossible in WordPress. Without using AJAX to filter the posts I don’t understand how I can show the specific posts I want based on whether they are sold or for sale.

    For example I changed to just normal posts with categories and tags. The 2 categories are [For Sale] and [Sold]. Then I use tags to show the types of businesses they are, example ‘Retail’.

    Now there doesn’t seem to be any way at all of creating a list of tags specific to the category that will link to a page that shows posts with that tag in that specific category. For example a page of posts that has the tag ‘Retail’ and are marked as ‘For Sale’.

    Does anybody know what I’m talking about here or am I missing something really basic?

    I created a page called ‘Businesses for sale’. And I show all the posts in the category [for sale]. That’s all good, but say I want a list of tags in the sidebar that will filter these businesses for sale. Its impossible right?

    If I click on a tag it shows every post that has that tag regardless of the category. Please help, cause I am about to give up on WordPress lol.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Marking Businesses for sale with custom taxonimies’ is closed to new replies.