Nathan, that's a very interesting idea! We currently do not have a helper function to do this, but if you know a little PHP you can hack it like this:
Change SimplePages/views/page/show.php to look like this:
<?php if (isset($wrapit) && $wrapit == false) : ?>
<?php echo eval('?>' . $page->text); ?>
<?php else: ?>
<?php head(array('title' => html_escape($page->title), 'bodyclass' => 'page', 'bodyid' => html_escape($page->slug))); ?>
<div id="primary">
<h1><?php echo html_escape($page->title); ?></h1>
<?php echo eval('?>' . $page->text); ?>
</div>
<?php echo foot(); ?>
<?php endif; ?>
In your index.php page, add this code to see the a simple page with the slug "about":
<?php
function getPageByPageSlug($pageSlug) {
$table = get_db()->getTable('SimplePagesPage');
$select = $table->getSelect();
$select->where('s.slug = ?', array($pageSlug));
$pages = $table->fetchObjects($select);
if ($pages) {
$page = $pages[0];
return $page;
} else {
return null;
}
}
$pageSlug = 'about';
$page = getPageByPageSlug($pageSlug);
if ($page) {
echo $this->partial('page/show.php', array('page' => $page, 'wrapit' => false));
}
?>
Of course hacking SimplePages like this will mean that if you upgrade SimplePages, you'll need to replace the page/show.php page again.
Let me know if this helps. I'll see if we can add a helper function to make this easier in the next version of SimplePages.