Hi. I have a huge conditional that I am using to refine results.
If I use this conditional with an if:else, regardless if there are any results it displays both.
See code below:
{if segment_2 == "" XOR (segment_2 == "africa" AND continent == "Africa") XOR (segment_2 == "antarctica" AND continent == "Antarctica") XOR (segment_2 == "asia" AND continent == "Asia") XOR (segment_2 == "australia" AND continent == "Australia") XOR (segment_2 == "europe" AND continent == "Europe") XOR (segment_2 == "north_america" AND continent == "North America") XOR (segment_2 == "south_america" AND continent == "south_america") XOR (segment_2 == "-500" AND tour_price <= "500") XOR (segment_2 == "500-1000" AND (tour_price >= "500" AND tour_price <= "1000")) XOR (segment_2 == "1000-2000" AND (tour_price >= "1000" AND tour_price <= "2000")) XOR (segment_2 == "2000+" AND tour_price >= "2000") XOR (segment_2 == "easy" AND tour_exertion == "Easy") XOR (segment_2 == "hard" AND tour_exertion == "Hard")}
...content to show if…
{if:else}
Ooops, nothing available
{/if}The ‘Ooops, nothing available’ displays once when there are results, and twice when there arent…
Can anyone see a reason why? Is my conditional way too long? possibly a better way to achieve this?
Thanks