Disable search-dropdown if captcha is required
authorMarcel Werk <burntime@woltlab.com>
Tue, 26 Feb 2019 17:46:02 +0000 (18:46 +0100)
committerMarcel Werk <burntime@woltlab.com>
Tue, 26 Feb 2019 17:46:02 +0000 (18:46 +0100)
Closes #2856

com.woltlab.wcf/templates/pageHeaderUser.tpl

index f52e8456e3263edf39f9f43babfe1107bbe5f14f..ad55fefe2150b3d7829da71b3b02050fc9ef657c 100644 (file)
                {/if}
                
                <!-- page search -->
-               <li class="jsOnly">
-                       <a href="#" id="userPanelSearchButton" class="jsTooltip" title="{lang}wcf.global.search{/lang}"><span class="icon icon32 fa-search"></span> <span>{lang}wcf.global.search{/lang}</span></a>
-               </li>
+               {if !SEARCH_USE_CAPTCHA || $__wcf->user->userID}
+                       <li class="jsOnly">
+                               <a href="#" id="userPanelSearchButton" class="jsTooltip" title="{lang}wcf.global.search{/lang}"><span class="icon icon32 fa-search"></span> <span>{lang}wcf.global.search{/lang}</span></a>
+                       </li>
+               {else}
+                       <li>
+                               <a href="{link controller='Search'}{/link}" class="jsTooltip" title="{lang}wcf.global.search{/lang}"><span class="icon icon32 fa-search"></span> <span>{lang}wcf.global.search{/lang}</span></a>
+                       </li>
+               {/if}
        </ul>
 </nav>