Commit d0c9c577 authored by Jonathan.Wage's avatar Jonathan.Wage

Fixes for api documentation styling and manual urls.

parent 48dbf083
......@@ -23,6 +23,10 @@ download:
url: /download
param: { module: main, action: download }
manual_chapter:
url: /documentation/manual/:chapter
param: { module: manual, action: index }
manual:
url: /documentation/manual/*
param: { module: manual, action: index }
......
<ul>
<li>DQL (Doctrine Query Language)</li>
<li>Native SQL</li>
<li>Class Templates</li>
<li>Hierarchical Data</li>
<li>Supports most database types</li>
<li>Transactions</li>
<li>Caching</li>
<li>Fulltext Indexing/Searching</li>
<li>Plugins</li>
<li><?php echo link_to('DQL (Doctrine Query Language)', '@manual_chapter?chapter=dql-doctrine-query-language'); ?></li>
<li><?php echo link_to('Native SQL', '@manual_chapter?chapter=native-sql'); ?></li>
<li><?php echo link_to('Class Templates', '@manual_chapter?chapter=class-templates'); ?></li>
<li><?php echo link_to('Hierarchical Data', '@manual_chapter?chapter=hierarchical-data'); ?></li>
<li><?php echo link_to('Transactions', '@manual_chapter?chapter=transactions'); ?></li>
<li><?php echo link_to('Caching', '@manual_chapter?chapter=caching'); ?></li>
<li><?php echo link_to('Searching', '@manual_chapter?chapter=searching'); ?></li>
<li><?php echo link_to('Plugins', '@manual_chapter?chapter=Plugins'); ?></li>
</ul>
\ No newline at end of file
......@@ -214,9 +214,11 @@ class manualActions extends sfActions
$cache->save($this->toc, 'toc');
}
$format = $this->getRequestParameter('format');
// Which format to output docs
if (isset($_GET['format'])) {
$format = ucfirst(strtolower($_GET['format']));
if ($format) {
$format = ucfirst(strtolower($format));
switch ($format) {
case 'Xhtml':
......@@ -276,12 +278,12 @@ class manualActions extends sfActions
$viewIndex = true;
if (isset($_GET['one-page'])) {
if ($this->getRequest()->hasParameter('one-page')) {
$viewIndex = false;
}
if (isset($_GET['chapter'])) {
$section = $this->toc->findByPath($_GET['chapter']);
if ($this->getRequest()->hasParameter('chapter')) {
$section = $this->toc->findByPath($this->getRequestParameter('chapter'));
if ($section && $section->getLevel() === 1) {
$title = $this->renderer->getOption('title') . ' - Chapter '
......@@ -289,7 +291,7 @@ class manualActions extends sfActions
$this->renderer->setOptions(array(
'section' => $section,
'url_prefix' => '?chapter=',
'url_prefix' => 'manual/',
'title' => $title
));
......
......@@ -127,3 +127,8 @@ td.type,.folder-title,.method-result,.include-type{ font-style: italic; }
.cmd-synopsis { margin: 1em 0em }
.cmd-title { font-weight: bold }
.toc { margin-left: 2em; padding-left: 0em }
#wrapper #content
{
margin-right: 250px;
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment