| 
							
								 | 
							
							<?php
 | 
						
						
						
						
							 | 
							
								 | 
							
								$sample_searches_tags_reserved = ["new", "we're here"];
 | 
						
						
						
						
							 | 
							
								 | 
							
								$sample_searches_plain = ["language", "Australia"];
 | 
						
						
						
						
							 | 
							
								 | 
							
								$sample_searches_tags = ["chat", "official", "privacy", "android", "crypto"];
 | 
						
						
						
						
							 | 
							
								 | 
							
								$sample_searches_languages = [["en", "🇬🇧"], ["zh", "🇨🇳"]];
 | 
						
						
						
						
							 | 
							
								 | 
							
							
 | 
						
						
						
						
							 | 
							
								 | 
							
								$sample_searches = [];
 | 
						
						
						
						
							 | 
							
								 | 
							
							
 | 
						
						
						
						
							 | 
							
								 | 
							
								foreach ($sample_searches_tags_reserved as $tag) {
 | 
						
						
						
						
							 | 
							
								 | 
							
									$search = str_replace(" ", "-", $tag);
 | 
						
						
						
						
							 | 
							
								 | 
							
									$sample_searches[] = array("type" => "tag-reserved", "text" => "#$tag", "search" => "#$search");
 | 
						
						
						
						
							 | 
							
								 | 
							
								}
 | 
						
						
						
						
							 | 
							
								 | 
							
								foreach ($sample_searches_tags as $tag) {
 | 
						
						
						
						
							 | 
							
								 | 
							
									$search = str_replace(" ", "-", $tag);
 | 
						
						
						
						
							 | 
							
								 | 
							
									$sample_searches[] = array("type" => "tag", "text" => "#$tag", "search" => "#$search");
 | 
						
						
						
						
							 | 
							
								 | 
							
								}
 | 
						
						
						
						
							 | 
							
								 | 
							
								foreach ($sample_searches_plain as $text) {
 | 
						
						
						
						
							 | 
							
								 | 
							
									$sample_searches[] = array("type" => "plain", "text" => $text, "search" => $text);
 | 
						
						
						
						
							 | 
							
								 | 
							
								}
 | 
						
						
						
						
							 | 
							
								 | 
							
								foreach ($sample_searches_languages as $language_array) {
 | 
						
						
						
						
							 | 
							
								 | 
							
									$sample_searches[] = array("type" => "language", "text" => $language_array[1], "search" => "lang:" . $language_array[0]);
 | 
						
						
						
						
							 | 
							
								 | 
							
								}
 | 
						
						
						
						
							 | 
							
								 | 
							
							?>
 | 
						
						
						
						
							 | 
							
								 | 
							
							
 | 
						
						
						
						
							 | 
							
								 | 
							
							<div id="search-container" class="collapsed">
 | 
						
						
						
						
							 | 
							
								 | 
							
								<div id="search">
 | 
						
						
						
						
							 | 
							
								 | 
							
							<?php
 | 
						
						
						
						
							 | 
							
								 | 
							
								// Phantom element for alignnment
 | 
						
						
						
						
							 | 
							
								 | 
							
							?>
 | 
						
						
						
						
							 | 
							
								 | 
							
									<div></div>
 | 
						
						
						
						
							 | 
							
								 | 
							
									<input id="search-bar" autocomplete="off" type="text" placeholder="Search for Communities">
 | 
						
						
						
						
							 | 
							
								 | 
							
									<div id="search-actions">
 | 
						
						
						
						
							 | 
							
								 | 
							
										<span id="btn-clear-search" class="btn-clear-search anchorstyle clickable enter-clicks" tabindex="0" title="Clear search">×</span>
 | 
						
						
						
						
							 | 
							
								 | 
							
										<span id="btn-share-search" class="anchorstyle clickable enter-clicks" tabindex="0">Share</span>
 | 
						
						
						
						
							 | 
							
								 | 
							
									</div>
 | 
						
						
						
						
							 | 
							
								 | 
							
								</div>
 | 
						
						
						
						
							 | 
							
								 | 
							
								<div id="sample-searches">
 | 
						
						
						
						
							 | 
							
								 | 
							
							<?php foreach ($sample_searches as $search): ?>
 | 
						
						
						
						
							 | 
							
								 | 
							
									<span
 | 
						
						
						
						
							 | 
							
								 | 
							
										class="badge clickable enter-clicks sample-search sample-search-<?=$search['type']?>"
 | 
						
						
						
						
							 | 
							
								 | 
							
										title="Try searching for <?=$search['search']?>"
 | 
						
						
						
						
							 | 
							
								 | 
							
										data-search="<?=$search['search']?>"
 | 
						
						
						
						
							 | 
							
								 | 
							
										tabindex=0
 | 
						
						
						
						
							 | 
							
								 | 
							
									><?=
 | 
						
						
						
						
							 | 
							
								 | 
							
										$search['text']
 | 
						
						
						
						
							 | 
							
								 | 
							
									?></span>
 | 
						
						
						
						
							 | 
							
								 | 
							
							<?php endforeach; ?>
 | 
						
						
						
						
							 | 
							
								 | 
							
								</div>
 | 
						
						
						
						
							 | 
							
								 | 
							
							</div>
 |