function ktz_get_AGC() { if (ot_get_option('ktz_agc_activated') == 'yes') { $s = $_GET['s']; if (isset($_REQUEST['s'])) { $termstring = urldecode($_REQUEST['s']); } else { $termstring = ''; } $termstring = $s; if ($s != '') { $googleresults = perform_google_web_search($termstring); if (is_array($googleresults)) { foreach ($googleresults as $result) { $link = urldecode(CleanFileNameBan(strip_tags($result['Oriurl']))); print '<div class="entry-search">'; print '<h3 class="entry-title"><a href="' . get_search_link(CleanFileNameBan(hilangkan_spesial_karakter($result['title']))) . '">' . CleanFileNameBan(hilangkan_spesial_karakter($result['title'])) . '</a></h3>'; print '<p>' . CleanFileNameBan(hilangkan_spesial_karakter($result['abstract'])) . '</p>'; print '<hr class="hr-dotted" />'; print '</div>'; } } } } else { ktz_post_notfound(); } }
} else { //get_template_part( 'content', get_post_format() ); } } ?> <nav id="nav-index"> <?php //ktz_navigation(); ?> </nav> <?php } else { $termstring = $s; if (ot_get_option('ktz_agc_activated') == "yes") { if ($s != '') { $googleresults = perform_google_web_search($termstring); if (is_array($googleresults)) { foreach ($googleresults as $result) { $link = urldecode(CleanFileNameBan(strip_tags($result['Oriurl']))); print '<div class="box-post ktz-agc-search">'; print '<h2><a href="' . get_search_link(CleanFileNameBan(hilangkan_spesial_karakter($result['title']))) . '">' . CleanFileNameBan(hilangkan_spesial_karakter($result['title'])) . '</a></h2>'; print '<p>' . CleanFileNameBan(hilangkan_spesial_karakter($result['abstract'])) . '</p>'; print '<p>Sumber: ' . $result['Oriurl'] . '</p>'; print '</div>'; } } } } else { //ktz_post_notfound(); } }