• Hi I’m trying to create a loop where posts for a custom taxonomy gets queried first, if there are not any then query through a secondary taxonomy

    I tried using custom taxonomy ordering plugin with autosort enabled but that didn’t work.

    Is that possible with this plugin?

    This is what I have going so far for reference:

    <ul>
    [loop type=post count=3 taxonomy=media_type term=articles relation=and taxonomy_2=industries term_2=healthcare,any-industry]
      <li>[field image]
    <div class="right-col"><h5>[field title-link]</h5><p>[field excerpt]</p></div>
      </li>
      [if count=2 compare=more]
       <a class="nectar-button small see-through accent-color has-icon" href="/resources/?_sft_media_type=articles&_sft_industries=healthcare,any-industry"><span>See More Related Articles</span><i class="icon-button-arrow" style="color: rgb(0, 0, 0);"></i></a>
      [/if]
    [/loop]
    </ul>
Viewing 1 replies (of 1 total)
  • Use loop-count

    Run loop-count for both taxonomy loops separately, then you can descide what query to use in content loop.

Viewing 1 replies (of 1 total)
  • The topic ‘Order posts loop by term order’ is closed to new replies.