fetch(); $records = $count['num_records']; if (isset($_GET['i'])) { $id = ($_GET['i'] <= $records) ? (int) $_GET['i'] : 1; $where = 'WHERE id = ' . $id . ' '; } $entries = new Mysql('SELECT * FROM jc_portfolio ' . $where . 'ORDER BY RAND() LIMIT 1'); $entry = $entries->fetch(); $previous = ($entry['id'] == 1) ? $records : $entry['id'] - 1; $next = ($entry['id'] == $records) ? 1 : $entry['id'] + 1; $page_title = 'Portfolio'; $meta_description = 'Some of the web work I have accomplished over the years.'; $main_heading = 'Some Of My Professional Work'; $scripts = array('portfolio.php'); require(INCLUDE_PATH . 'header.inc'); ?>
of