Beispiel #1
0
							<li class="active"><strong>Search Result</strong></li>
						</ol>
					</div>
				</div>
			</div>
		</section>
		<section class="portfolio-container">
			<div class="container">
				<div class="row" id="portfolio-items">
				<?php 
        $kata = $val->validasi($_GET['search'], 'xss');
        $p = new Paging();
        $batas = 5;
        $posisi = $p->cariPosisi($batas);
        $tablesearch = new PoTable('post');
        $searchposts = $tablesearch->findSearchPost($kata, "{$posisi},{$batas}");
        $numsearchposts = $tablesearch->numRowSearchPost($kata);
        if ($numsearchposts > 0) {
            ?>
				<?php 
            foreach ($searchposts as $searchpost) {
                $tabledscom = new PoTable('comment');
                $totaldscom = $tabledscom->numRowByAnd(id_post, $searchpost->id_post, active, 'Y');
                $tablecatds = new PoTable('category');
                $currentCatds = $tablecatds->findBy(id_category, $searchpost->id_category);
                $currentCatds = $currentCatds->current();
                $tableuser = new PoTable('users');
                $currentUser = $tableuser->findBy(id_user, $searchpost->editor);
                $currentUser = $currentUser->current();
                ?>
					<div class="item col-sm-4">