function page_url($page_id) { $CI =& get_instance(); $CI->load->model('Page'); $page = $CI->Page->load($page_id); if ($page) { return site_detect_url('site/' . urltitle($page->menu_title)); } }
<?php $moduletitle = "Help, Support and Credits"; include KNIFE_PATH . '/documentation.php'; $main_content .= '<h2 id="toc">Table of contents</h2><ul>'; foreach ($documentation as $null => $data) { $main_content .= "<li><a href=\"#" . urltitle($data[title]) . "\">{$data['title']}</a></li>"; } $main_content .= '</ul>'; foreach ($documentation as $null => $data) { $main_content .= "<h3 id=\"" . urlTitle($data[title]) . "\">{$data['title']} ^ <small><a href=\"#toc\">back</a></small></h3>"; $main_content .= '<div>' . $data[content] . '</div>'; } $main_content .= ' <h2>Credits</h2> <p><strong>Icons</strong>: <a href="http://zeus.qballcow.nl/icon/">Gartoon</a> by Zeus</p> <p>Language credit (autogenerated from the files)</p> <p>Development credit</p> ';