<?php $objCatalogue = new Catalogue(); $srch = Url::getParam('srch'); if (!empty($srch)) { $products = $objCatalogue->getAllProducts($srch); $empty = 'There are no results matching your searching criteria.'; } else { $products = $objCatalogue->getAllProducts(); $empty = 'There are currently no records.'; } $objPaging = new Paging($products, 5); $rows = $objPaging->getRecords(); $objPaging->_url = '/admin' . $objPaging->_url; require_once 'template/_header.php'; ?> <h1>Products</h1> <form action="" method="get"> <?php echo Url::getParams4Search(array('srch', Paging::$_key)); ?> <table cellpadding="0" cellspacing="0" border="0" class="tbl_insert"> <tr> <th><label for="srch">Product:</label></th> <td> <input type="text" name="srch" id="srch" value="<?php echo stripslashes($srch);