From: Laury GvR Date: Tue, 7 Nov 2017 22:15:50 +0000 (-0500) Subject: Fixing the extra commas showing up on alpha key member db list search results terms X-Git-Tag: v1.0.0^2~2 X-Git-Url: http://cvs2.gaslightmedia.com/gitweb/?a=commitdiff_plain;h=551b52bbcde10828eb6e9790a69bd5be63f68cef;p=WP-Themes%2Fmichigantrailmaps.git Fixing the extra commas showing up on alpha key member db list search results terms --- diff --git a/glm-member-db/views/front/members/list.html b/glm-member-db/views/front/members/list.html index 9d848d0..d884c93 100644 --- a/glm-member-db/views/front/members/list.html +++ b/glm-member-db/views/front/members/list.html @@ -5,21 +5,20 @@ Search Terms: {$termCounter = 0} {foreach $smarty.request as $key=>$value} + {if is_array($value) && $value[0] && $value[0] !== '' } {if $key !== 'action' && $key !== 'submit' && $key !== 'categories' } {if $key !== 'textSearch'} - {if $value[0]} {if $key === 'regionUserSearch'} {$key = 'regions'} {/if} {if $termCounter > 0}, {/if}{$searchParams->$key->$value[0]->name} - {$termCounter = $termCounter + 1} - {/if} + {$termCounter = $termCounter + 1} {else} {if $termCounter > 0}, {/if}{$value} {$termCounter = $termCounter + 1} {/if} {elseif $key === 'categories'} - {foreach $value as $index=>$id} + {foreach $value as $index=>$id} {if $index == 0 && $id} {if $termCounter > 0}, {/if}{$searchParams->destinations->{$id}->name}{$termCounter = $termCounter + 1} {else if $index == 1 && $id} @@ -27,9 +26,9 @@ Search Terms: {else if $index == 2 && $id} {if $termCounter > 0}, {/if}{$searchParams->parks->{$id}->name}{$termCounter = $termCounter + 1} {/if} - {/foreach} + {/foreach} {/if} - + {/if} {/foreach} {/if} @@ -248,9 +247,9 @@ Search Terms:
{if $settings.list_show_search_alpha} {/if}