title: Wordpress, list all taxonomies for custom post type with permalink
body: <p>Is there any easy way to list all taxonomies for custom post type with permalinks?</p>
  
  <p><code>taxonomy=title&amp;post_type=company</code></p>
  
  <p>The following does not seams to work, it is listing the categories for posts only:</p>
  
  <pre><code>$args = array (
      'type' =&gt; 'company', //your custom post type
      'orderby' =&gt; 'name',
      'order' =&gt; 'ASC',
      'hide_empty' =&gt; 0 //shows empty categories
  );
  $categories = get_categories( $args );
  foreach ($categories as $category) {    
      echo $category-&gt;name;
      $post_by_cat = get_posts(array('cat' =&gt; $category-&gt;term_id));
  
      echo '&lt;ul&gt;';
      foreach( $post_by_cat as $post ) {
          setup_postdata($post);
          echo '&lt;li&gt;&lt;a href="'.the_permalink().'"&gt;'.the_title().'&lt;/a&gt;&lt;/li&gt;';
      }
      echo '&lt;/ul&gt;';
  }
  </code></pre>