12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411 |
- <!DOCTYPE html>
- <html lang="en">
- <head>
- <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0"/>
- <meta charset="utf-8"/>
- <title>Pico 1.0 API Documentation</title>
- <meta name="author" content=""/>
- <meta name="description" content=""/>
- <link href="../css/bootstrap-combined.no-icons.min.css" rel="stylesheet">
- <link href="../css/font-awesome.min.css" rel="stylesheet">
- <link href="../css/prism.css" rel="stylesheet" media="all"/>
- <link href="../css/template.css" rel="stylesheet" media="all"/>
-
- <!--[if lt IE 9]>
- <script src="../js/html5.js"></script>
- <![endif]-->
- <script src="../js/jquery-1.11.0.min.js"></script>
- <script src="../js/ui/1.10.4/jquery-ui.min.js"></script>
- <script src="../js/bootstrap.min.js"></script>
- <script src="../js/jquery.smooth-scroll.js"></script>
- <script src="../js/prism.min.js"></script>
- <!-- TODO: Add http://jscrollpane.kelvinluck.com/ to style the scrollbars for browsers not using webkit-->
- <script type="text/javascript">
- function loadExternalCodeSnippets() {
- Array.prototype.slice.call(document.querySelectorAll('pre[data-src]')).forEach(function (pre) {
- var src = pre.getAttribute('data-src');
- var extension = (src.match(/\.(\w+)$/) || [, ''])[1];
- var language = 'php';
- var code = document.createElement('code');
- code.className = 'language-' + language;
- pre.textContent = '';
- code.textContent = 'Loading…';
- pre.appendChild(code);
- var xhr = new XMLHttpRequest();
- xhr.open('GET', src, true);
- xhr.onreadystatechange = function () {
- if (xhr.readyState == 4) {
- if (xhr.status < 400 && xhr.responseText) {
- code.textContent = xhr.responseText;
- Prism.highlightElement(code);
- }
- else if (xhr.status >= 400) {
- code.textContent = '✖ Error ' + xhr.status + ' while fetching file: ' + xhr.statusText;
- }
- else {
- code.textContent = '✖ Error: File does not exist or is empty';
- }
- }
- };
- xhr.send(null);
- });
- }
- $(document).ready(function(){
- loadExternalCodeSnippets();
- });
- $('#source-view').on('shown', function () {
- loadExternalCodeSnippets();
- })
- </script>
- <link rel="shortcut icon" href="../images/favicon.ico"/>
- <link rel="apple-touch-icon" href="../images/apple-touch-icon.png"/>
- <link rel="apple-touch-icon" sizes="72x72" href="../images/apple-touch-icon-72x72.png"/>
- <link rel="apple-touch-icon" sizes="114x114" href="../images/apple-touch-icon-114x114.png"/>
- </head>
- <body>
- <div class="navbar navbar-fixed-top">
- <div class="navbar-inner">
- <div class="container">
- <a class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse">
- <i class="icon-ellipsis-vertical"></i>
- </a>
- <a class="brand" href="../index.html">Pico 1.0 API Documentation</a>
- <div class="nav-collapse">
- <ul class="nav pull-right">
- <li class="dropdown" id="charts-menu">
- <a href="#" class="dropdown-toggle" data-toggle="dropdown">
- Charts <b class="caret"></b>
- </a>
- <ul class="dropdown-menu">
- <li>
- <a href="../graphs/class.html">
- <i class="icon-list-alt"></i> Class hierarchy diagram
- </a>
- </li>
- </ul>
- </li>
- <li class="dropdown" id="reports-menu">
- <a href="#" class="dropdown-toggle" data-toggle="dropdown">
- Reports <b class="caret"></b>
- </a>
- <ul class="dropdown-menu">
- <li>
- <a href="../reports/errors.html">
- <i class="icon-list-alt"></i> Errors <span class="label label-info pull-right">19</span>
- </a>
- </li>
- <li>
- <a href="../reports/markers.html">
- <i class="icon-list-alt"></i> Markers <span class="label label-info pull-right">1</span>
- </a>
- </li>
- <li>
- <a href="../reports/deprecated.html">
- <i class="icon-list-alt"></i> Deprecated <span class="label label-info pull-right">0</span>
- </a>
- </li>
- </ul>
- </li>
- </ul>
- </div>
- </div>
- </div>
- <!--<div class="go_to_top">-->
- <!--<a href="#___" style="color: inherit">Back to top  <i class="icon-upload icon-white"></i></a>-->
- <!--</div>-->
- </div>
- <div id="___" class="container-fluid">
- <section class="row-fluid">
- <div class="span2 sidebar">
- <div class="accordion" style="margin-bottom: 0">
- <div class="accordion-group">
- <div class="accordion-heading">
- <a class="accordion-toggle " data-toggle="collapse" data-target="#namespace-1354212884"></a>
- <a href="../namespaces/default.html" style="margin-left: 30px; padding-left: 0">\</a>
- </div>
- <div id="namespace-1354212884" class="accordion-body collapse in">
- <div class="accordion-inner">
-
- <ul>
- <li class="interface"><a href="../classes/PicoPluginInterface.html">PicoPluginInterface</a></li>
- <li class="class"><a href="../classes/AbstractPicoPlugin.html">AbstractPicoPlugin</a></li>
- <li class="class"><a href="../classes/DummyPlugin.html">DummyPlugin</a></li>
- <li class="class"><a href="../classes/Pico.html">Pico</a></li>
- </ul>
- </div>
- </div>
- </div>
- </div>
- </div>
- </section>
- <section class="row-fluid">
- <div class="span10 offset2">
- <div class="row-fluid">
- <div class="span8 content class">
- <nav>
- <a href="../namespaces/default.html">\</a> <i class="icon-level-up"></i>
- </nav>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal"><i class="icon-code"></i></a>
- <h1><small>\</small>Pico</h1>
- <p><em>Pico</em></p>
- <p>Pico is a stupidly simple, blazing fast, flat file CMS.</p>
- <ul>
- <li>Stupidly Simple: Picos makes creating and maintaining a
- website as simple as editing text files.</li>
- <li>Blazing Fast: Pico is seriously lightweight and doesn't
- use a database, making it super fast.</li>
- <li>No Database: Pico is a "flat file" CMS, meaning no
- database woes, no MySQL queries, nothing.</li>
- <li>Markdown Formatting: Edit your website in your favourite
- text editor using simple Markdown formatting.</li>
- <li>Twig Templates: Pico uses the Twig templating engine,
- for powerful and flexible themes.</li>
- <li>Open Source: Pico is completely free and open source,
- released under the MIT license.
- See <a href="http://picocms.org/">http://picocms.org/</a> for more info.</li>
- </ul>
-
-
- <section id="summary">
- <h2>Summary</h2>
- <section class="row-fluid heading">
- <section class="span4">
- <a href="#methods">Methods</a>
- </section>
- <section class="span4">
- <a href="#properties">Properties</a>
- </section>
- <section class="span4">
- <a href="#constants">Constants</a>
- </section>
- </section>
- <section class="row-fluid public">
- <section class="span4">
- <a href="../classes/Pico.html#method___construct" class="">__construct()</a><br />
- <a href="../classes/Pico.html#method_getRootDir" class="">getRootDir()</a><br />
- <a href="../classes/Pico.html#method_getConfigDir" class="">getConfigDir()</a><br />
- <a href="../classes/Pico.html#method_getPluginsDir" class="">getPluginsDir()</a><br />
- <a href="../classes/Pico.html#method_getThemesDir" class="">getThemesDir()</a><br />
- <a href="../classes/Pico.html#method_run" class="">run()</a><br />
- <a href="../classes/Pico.html#method_getPlugin" class="">getPlugin()</a><br />
- <a href="../classes/Pico.html#method_getPlugins" class="">getPlugins()</a><br />
- <a href="../classes/Pico.html#method_setConfig" class="">setConfig()</a><br />
- <a href="../classes/Pico.html#method_getConfig" class="">getConfig()</a><br />
- <a href="../classes/Pico.html#method_getRequestUrl" class="">getRequestUrl()</a><br />
- <a href="../classes/Pico.html#method_getRequestFile" class="">getRequestFile()</a><br />
- <a href="../classes/Pico.html#method_loadFileContent" class="">loadFileContent()</a><br />
- <a href="../classes/Pico.html#method_load404Content" class="">load404Content()</a><br />
- <a href="../classes/Pico.html#method_getRawContent" class="">getRawContent()</a><br />
- <a href="../classes/Pico.html#method_getMetaHeaders" class="">getMetaHeaders()</a><br />
- <a href="../classes/Pico.html#method_parseFileMeta" class="">parseFileMeta()</a><br />
- <a href="../classes/Pico.html#method_getFileMeta" class="">getFileMeta()</a><br />
- <a href="../classes/Pico.html#method_prepareFileContent" class="">prepareFileContent()</a><br />
- <a href="../classes/Pico.html#method_parseFileContent" class="">parseFileContent()</a><br />
- <a href="../classes/Pico.html#method_getFileContent" class="">getFileContent()</a><br />
- <a href="../classes/Pico.html#method_getPages" class="">getPages()</a><br />
- <a href="../classes/Pico.html#method_getCurrentPage" class="">getCurrentPage()</a><br />
- <a href="../classes/Pico.html#method_getPreviousPage" class="">getPreviousPage()</a><br />
- <a href="../classes/Pico.html#method_getNextPage" class="">getNextPage()</a><br />
- <a href="../classes/Pico.html#method_getTwig" class="">getTwig()</a><br />
- <a href="../classes/Pico.html#method_getBaseUrl" class="">getBaseUrl()</a><br />
- <a href="../classes/Pico.html#method_isUrlRewritingEnabled" class="">isUrlRewritingEnabled()</a><br />
- <a href="../classes/Pico.html#method_getPageUrl" class="">getPageUrl()</a><br />
- </section>
- <section class="span4">
- <em>No public properties found</em>
- </section>
- <section class="span4">
- <a href="../classes/Pico.html#constant_SORT_ASC" class="">SORT_ASC</a><br />
- <a href="../classes/Pico.html#constant_SORT_DESC" class="">SORT_DESC</a><br />
- <a href="../classes/Pico.html#constant_SORT_NONE" class="">SORT_NONE</a><br />
- </section>
- </section>
- <section class="row-fluid protected">
- <section class="span4">
- <a href="../classes/Pico.html#method_loadPlugins" class="">loadPlugins()</a><br />
- <a href="../classes/Pico.html#method_loadConfig" class="">loadConfig()</a><br />
- <a href="../classes/Pico.html#method_evaluateRequestUrl" class="">evaluateRequestUrl()</a><br />
- <a href="../classes/Pico.html#method_discoverRequestFile" class="">discoverRequestFile()</a><br />
- <a href="../classes/Pico.html#method_readPages" class="">readPages()</a><br />
- <a href="../classes/Pico.html#method_sortPages" class="">sortPages()</a><br />
- <a href="../classes/Pico.html#method_discoverCurrentPage" class="">discoverCurrentPage()</a><br />
- <a href="../classes/Pico.html#method_registerTwig" class="">registerTwig()</a><br />
- <a href="../classes/Pico.html#method_getTwigVariables" class="">getTwigVariables()</a><br />
- <a href="../classes/Pico.html#method_getFiles" class="">getFiles()</a><br />
- <a href="../classes/Pico.html#method_getAbsolutePath" class="">getAbsolutePath()</a><br />
- <a href="../classes/Pico.html#method_triggerEvent" class="">triggerEvent()</a><br />
- </section>
- <section class="span4">
- <a href="../classes/Pico.html#property_rootDir" class="">$rootDir</a><br />
- <a href="../classes/Pico.html#property_configDir" class="">$configDir</a><br />
- <a href="../classes/Pico.html#property_pluginsDir" class="">$pluginsDir</a><br />
- <a href="../classes/Pico.html#property_themesDir" class="">$themesDir</a><br />
- <a href="../classes/Pico.html#property_locked" class="">$locked</a><br />
- <a href="../classes/Pico.html#property_plugins" class="">$plugins</a><br />
- <a href="../classes/Pico.html#property_config" class="">$config</a><br />
- <a href="../classes/Pico.html#property_requestUrl" class="">$requestUrl</a><br />
- <a href="../classes/Pico.html#property_requestFile" class="">$requestFile</a><br />
- <a href="../classes/Pico.html#property_rawContent" class="">$rawContent</a><br />
- <a href="../classes/Pico.html#property_meta" class="">$meta</a><br />
- <a href="../classes/Pico.html#property_content" class="">$content</a><br />
- <a href="../classes/Pico.html#property_pages" class="">$pages</a><br />
- <a href="../classes/Pico.html#property_currentPage" class="">$currentPage</a><br />
- <a href="../classes/Pico.html#property_previousPage" class="">$previousPage</a><br />
- <a href="../classes/Pico.html#property_nextPage" class="">$nextPage</a><br />
- <a href="../classes/Pico.html#property_twig" class="">$twig</a><br />
- <a href="../classes/Pico.html#property_twigVariables" class="">$twigVariables</a><br />
- </section>
- <section class="span4">
- <em>N/A</em>
- </section>
- </section>
- <section class="row-fluid private">
- <section class="span4">
- <em>No private methods found</em>
- </section>
- <section class="span4">
- <em>No private properties found</em>
- </section>
- <section class="span4">
- <em>N/A</em>
- </section>
- </section>
- </section>
- </div>
- <aside class="span4 detailsbar">
-
-
- <dl>
- <dt>File</dt>
- <dd><a href="../files/lib.Pico.html"><div class="path-wrapper">lib/Pico.php</div></a></dd>
- <dt>Package</dt>
- <dd><div class="namespace-wrapper">Default</div></dd>
- <dt>Class hierarchy</dt>
- <dd class="hierarchy">
- <div class="namespace-wrapper">\Pico</div>
- </dd>
-
-
-
- <dt>See also</dt>
- <dd><a href="<http://picocms.org>"><span class="namespace-wrapper"><http://picocms.org></span></a></dd>
-
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr>
- <th>
- author
- </th>
- <td>
- <p>Gilbert Pellegrom</p>
- <p>Daniel Rudolf</p>
- </td>
- </tr>
- <tr>
- <th>
- license
- </th>
- <td>
- <p>The MIT License <a href="http://opensource.org/licenses/MIT">http://opensource.org/licenses/MIT</a></p>
- </td>
- </tr>
- <tr>
- <th>
- version
- </th>
- <td>
-
- </td>
- </tr>
- </table>
- </aside>
- </div>
- <a id="constants" name="constants"></a>
- <div class="row-fluid">
- <div class="span8 content class">
- <h2>Constants</h2>
- </div>
- <aside class="span4 detailsbar"></aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="constant_SORT_ASC" name="constant_SORT_ASC" class="anchor"></a>
- <article id="constant_SORT_ASC" class="constant">
- <h3 class="">SORT_ASC</h3>
- <pre class="signature">SORT_ASC</pre>
- <p><em>Sort files in alphabetical ascending order</em></p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getFiles"><span class="namespace-wrapper">\Pico::getFiles()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="constant_SORT_DESC" name="constant_SORT_DESC" class="anchor"></a>
- <article id="constant_SORT_DESC" class="constant">
- <h3 class="">SORT_DESC</h3>
- <pre class="signature">SORT_DESC</pre>
- <p><em>Sort files in alphabetical descending order</em></p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getFiles"><span class="namespace-wrapper">\Pico::getFiles()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="constant_SORT_NONE" name="constant_SORT_NONE" class="anchor"></a>
- <article id="constant_SORT_NONE" class="constant">
- <h3 class="">SORT_NONE</h3>
- <pre class="signature">SORT_NONE</pre>
- <p><em>Don't sort files</em></p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getFiles"><span class="namespace-wrapper">\Pico::getFiles()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
-
- <a id="properties" name="properties"></a>
- <div class="row-fluid">
- <div class="span8 content class">
- <h2>Properties</h2>
- </div>
- <aside class="span4 detailsbar"></aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="property_rootDir" name="property_rootDir" class="anchor"></a>
- <article class="property">
- <h3 class="protected ">$rootDir</h3>
- <pre class="signature">$rootDir : string</pre>
- <p><em>Root directory of this Pico instance</em></p>
-
- <h4>Type</h4>
- string
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getRootDir"><span class="namespace-wrapper">\Pico::getRootDir()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="property_configDir" name="property_configDir" class="anchor"></a>
- <article class="property">
- <h3 class="protected ">$configDir</h3>
- <pre class="signature">$configDir : string</pre>
- <p><em>Config directory of this Pico instance</em></p>
-
- <h4>Type</h4>
- string
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getConfigDir"><span class="namespace-wrapper">\Pico::getConfigDir()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="property_pluginsDir" name="property_pluginsDir" class="anchor"></a>
- <article class="property">
- <h3 class="protected ">$pluginsDir</h3>
- <pre class="signature">$pluginsDir : string</pre>
- <p><em>Plugins directory of this Pico instance</em></p>
-
- <h4>Type</h4>
- string
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getPluginsDir"><span class="namespace-wrapper">\Pico::getPluginsDir()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="property_themesDir" name="property_themesDir" class="anchor"></a>
- <article class="property">
- <h3 class="protected ">$themesDir</h3>
- <pre class="signature">$themesDir : string</pre>
- <p><em>Themes directory of this Pico instance</em></p>
-
- <h4>Type</h4>
- string
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getThemesDir"><span class="namespace-wrapper">\Pico::getThemesDir()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="property_locked" name="property_locked" class="anchor"></a>
- <article class="property">
- <h3 class="protected ">$locked</h3>
- <pre class="signature">$locked : boolean</pre>
- <p><em>Boolean indicating whether Picos processing started yet</em></p>
-
- <h4>Type</h4>
- boolean
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="property_plugins" name="property_plugins" class="anchor"></a>
- <article class="property">
- <h3 class="protected ">$plugins</h3>
- <pre class="signature">$plugins : array<mixed,object>|null</pre>
- <p><em>List of loaded plugins</em></p>
-
- <h4>Type</h4>
- array<mixed,object>|null
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getPlugins"><span class="namespace-wrapper">\Pico::getPlugins()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="property_config" name="property_config" class="anchor"></a>
- <article class="property">
- <h3 class="protected ">$config</h3>
- <pre class="signature">$config : array<mixed,mixed>|null</pre>
- <p><em>Current configuration of this Pico instance</em></p>
-
- <h4>Type</h4>
- array<mixed,mixed>|null
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getConfig"><span class="namespace-wrapper">\Pico::getConfig()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="property_requestUrl" name="property_requestUrl" class="anchor"></a>
- <article class="property">
- <h3 class="protected ">$requestUrl</h3>
- <pre class="signature">$requestUrl : string|null</pre>
- <p><em>Part of the URL describing the requested contents</em></p>
-
- <h4>Type</h4>
- string|null
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getRequestUrl"><span class="namespace-wrapper">\Pico::getRequestUrl()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="property_requestFile" name="property_requestFile" class="anchor"></a>
- <article class="property">
- <h3 class="protected ">$requestFile</h3>
- <pre class="signature">$requestFile : string|null</pre>
- <p><em>Absolute path to the content file being served</em></p>
-
- <h4>Type</h4>
- string|null
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getRequestFile"><span class="namespace-wrapper">\Pico::getRequestFile()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="property_rawContent" name="property_rawContent" class="anchor"></a>
- <article class="property">
- <h3 class="protected ">$rawContent</h3>
- <pre class="signature">$rawContent : string|null</pre>
- <p><em>Raw, not yet parsed contents to serve</em></p>
-
- <h4>Type</h4>
- string|null
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getRawContent"><span class="namespace-wrapper">\Pico::getRawContent()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="property_meta" name="property_meta" class="anchor"></a>
- <article class="property">
- <h3 class="protected ">$meta</h3>
- <pre class="signature">$meta : array<mixed,string>|null</pre>
- <p><em>Meta data of the page to serve</em></p>
-
- <h4>Type</h4>
- array<mixed,string>|null
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getFileMeta"><span class="namespace-wrapper">\Pico::getFileMeta()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="property_content" name="property_content" class="anchor"></a>
- <article class="property">
- <h3 class="protected ">$content</h3>
- <pre class="signature">$content : string|null</pre>
- <p><em>Parsed content being served</em></p>
-
- <h4>Type</h4>
- string|null
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getFileContent"><span class="namespace-wrapper">\Pico::getFileContent()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="property_pages" name="property_pages" class="anchor"></a>
- <article class="property">
- <h3 class="protected ">$pages</h3>
- <pre class="signature">$pages : array<mixed,array>|null</pre>
- <p><em>List of known pages</em></p>
-
- <h4>Type</h4>
- array<mixed,array>|null
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getPages"><span class="namespace-wrapper">\Pico::getPages()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="property_currentPage" name="property_currentPage" class="anchor"></a>
- <article class="property">
- <h3 class="protected ">$currentPage</h3>
- <pre class="signature">$currentPage : array|null</pre>
- <p><em>Data of the page being served</em></p>
-
- <h4>Type</h4>
- array|null
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getCurrentPage"><span class="namespace-wrapper">\Pico::getCurrentPage()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="property_previousPage" name="property_previousPage" class="anchor"></a>
- <article class="property">
- <h3 class="protected ">$previousPage</h3>
- <pre class="signature">$previousPage : array|null</pre>
- <p><em>Data of the previous page relative to the page being served</em></p>
-
- <h4>Type</h4>
- array|null
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getPreviousPage"><span class="namespace-wrapper">\Pico::getPreviousPage()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="property_nextPage" name="property_nextPage" class="anchor"></a>
- <article class="property">
- <h3 class="protected ">$nextPage</h3>
- <pre class="signature">$nextPage : array|null</pre>
- <p><em>Data of the next page relative to the page being served</em></p>
-
- <h4>Type</h4>
- array|null
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getNextPage"><span class="namespace-wrapper">\Pico::getNextPage()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="property_twig" name="property_twig" class="anchor"></a>
- <article class="property">
- <h3 class="protected ">$twig</h3>
- <pre class="signature">$twig : \Twig_Environment|null</pre>
- <p><em>Twig instance used for template parsing</em></p>
-
- <h4>Type</h4>
- \Twig_Environment|null
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getTwig"><span class="namespace-wrapper">\Pico::getTwig()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="property_twigVariables" name="property_twigVariables" class="anchor"></a>
- <article class="property">
- <h3 class="protected ">$twigVariables</h3>
- <pre class="signature">$twigVariables : array<mixed,mixed>|null</pre>
- <p><em>Variables passed to the twig template</em></p>
-
- <h4>Type</h4>
- array<mixed,mixed>|null
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href=""><span class="namespace-wrapper">\Pico::getTwigVariables</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
-
- <a id="methods" name="methods"></a>
- <div class="row-fluid">
- <div class="span8 content class"><h2>Methods</h2></div>
- <aside class="span4 detailsbar"></aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method___construct" name="method___construct" class="anchor"></a>
- <article class="method">
- <h3 class="public ">__construct()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">__construct(string <span class="argument">$rootDir</span>, string <span class="argument">$configDir</span>, string <span class="argument">$pluginsDir</span>, string <span class="argument">$themesDir</span>) </pre>
- <p><em>Constructs a new Pico instance</em></p>
- <p>To carry out all the processing in Pico, call <a href="/classes/Pico.html#method_run">Pico::run()</a>.</p>
- <h4>Parameters</h4>
- <table class="table table-condensed table-hover">
- <tr>
- <td>string</td>
- <td>$rootDir </td>
- <td><p>root directory of this Pico instance</p></td>
- </tr>
- <tr>
- <td>string</td>
- <td>$configDir </td>
- <td><p>config directory of this Pico instance</p></td>
- </tr>
- <tr>
- <td>string</td>
- <td>$pluginsDir </td>
- <td><p>plugins directory of this Pico instance</p></td>
- </tr>
- <tr>
- <td>string</td>
- <td>$themesDir </td>
- <td><p>themes directory of this Pico instance</p></td>
- </tr>
- </table>
-
-
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getRootDir" name="method_getRootDir" class="anchor"></a>
- <article class="method">
- <h3 class="public ">getRootDir()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getRootDir() : string</pre>
- <p><em>Returns the root directory of this Pico instance</em></p>
-
-
-
- <h4>Returns</h4>
- string
- — <p>root directory path</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getConfigDir" name="method_getConfigDir" class="anchor"></a>
- <article class="method">
- <h3 class="public ">getConfigDir()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getConfigDir() : string</pre>
- <p><em>Returns the config directory of this Pico instance</em></p>
-
-
-
- <h4>Returns</h4>
- string
- — <p>config directory path</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getPluginsDir" name="method_getPluginsDir" class="anchor"></a>
- <article class="method">
- <h3 class="public ">getPluginsDir()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getPluginsDir() : string</pre>
- <p><em>Returns the plugins directory of this Pico instance</em></p>
-
-
-
- <h4>Returns</h4>
- string
- — <p>plugins directory path</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getThemesDir" name="method_getThemesDir" class="anchor"></a>
- <article class="method">
- <h3 class="public ">getThemesDir()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getThemesDir() : string</pre>
- <p><em>Returns the themes directory of this Pico instance</em></p>
-
-
-
- <h4>Returns</h4>
- string
- — <p>themes directory path</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_run" name="method_run" class="anchor"></a>
- <article class="method">
- <h3 class="public ">run()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">run() : string</pre>
- <p><em>Runs this Pico instance</em></p>
- <p>Loads plugins, evaluates the config file, does URL routing, parses
- meta headers, processes Markdown, does Twig processing and returns
- the rendered contents.</p>
-
-
- <h4>Returns</h4>
- string
- — <p>rendered Pico contents</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getPlugin" name="method_getPlugin" class="anchor"></a>
- <article class="method">
- <h3 class="public ">getPlugin()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getPlugin(string <span class="argument">$pluginName</span>) : object</pre>
- <p><em>Returns the instance of a named plugin</em></p>
- <p>Plugins SHOULD implement <a href="/classes/PicoPluginInterface.html">PicoPluginInterface</a>, but you MUST NOT
- rely on it. For more information see <a href="/classes/PicoPluginInterface.html">PicoPluginInterface</a>.</p>
- <h4>Parameters</h4>
- <table class="table table-condensed table-hover">
- <tr>
- <td>string</td>
- <td>$pluginName </td>
- <td><p>name of the plugin</p></td>
- </tr>
- </table>
-
- <h4>Throws</h4>
- <dl>
- <dt>\RuntimeException</dt>
- <dd><p>thrown when the plugin wasn't found</p></dd>
- </dl>
-
- <h4>Returns</h4>
- object
- — <p>instance of the plugin</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_loadPlugins"><span class="namespace-wrapper">\Pico::loadPlugins()</span></a></dd>
- <dd><a href="../classes/Pico.html#method_getPlugins"><span class="namespace-wrapper">\Pico::getPlugins()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getPlugins" name="method_getPlugins" class="anchor"></a>
- <article class="method">
- <h3 class="public ">getPlugins()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getPlugins() : array<mixed,object>|null</pre>
- <p><em>Returns all loaded plugins</em></p>
-
-
-
- <h4>Returns</h4>
- array<mixed,object>|null
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_loadPlugins"><span class="namespace-wrapper">\Pico::loadPlugins()</span></a></dd>
- <dd><a href="../classes/Pico.html#method_getPlugin"><span class="namespace-wrapper">\Pico::getPlugin()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_setConfig" name="method_setConfig" class="anchor"></a>
- <article class="method">
- <h3 class="public ">setConfig()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">setConfig(array<mixed,mixed> <span class="argument">$config</span>) : void</pre>
- <p><em>Sets Picos config before calling Pico::run()</em></p>
- <p>This method allows you to modify Picos config without creating a
- {@path "config/config.php"} or changing some of its variables before
- Pico starts processing.</p>
- <p>You can call this method between <a href="/classes/Pico.html#method___construct">Pico::__construct()</a> and
- <a href="/classes/Pico.html#method_run">Pico::run()</a> only. Options set with this method cannot be
- overwritten by {@path "config/config.php"}.</p>
- <h4>Parameters</h4>
- <table class="table table-condensed table-hover">
- <tr>
- <td>array<mixed,mixed></td>
- <td>$config </td>
- <td><p>array with config variables</p></td>
- </tr>
- </table>
-
- <h4>Throws</h4>
- <dl>
- <dt>\RuntimeException</dt>
- <dd><p>thrown if Pico already started processing</p></dd>
- </dl>
-
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_loadConfig"><span class="namespace-wrapper">\Pico::loadConfig()</span></a></dd>
- <dd><a href="../classes/Pico.html#method_getConfig"><span class="namespace-wrapper">\Pico::getConfig()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getConfig" name="method_getConfig" class="anchor"></a>
- <article class="method">
- <h3 class="public ">getConfig()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getConfig(string <span class="argument">$configName = null</span>) : mixed</pre>
- <p><em>Returns either the value of the specified config variable or
- the config array</em></p>
-
- <h4>Parameters</h4>
- <table class="table table-condensed table-hover">
- <tr>
- <td>string</td>
- <td>$configName </td>
- <td><p>optional name of a config variable</p></td>
- </tr>
- </table>
-
-
- <h4>Returns</h4>
- mixed
- — <p>returns either the value of the named config
- variable, null if the config variable doesn't exist or the config
- array if no config name was supplied</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_setConfig"><span class="namespace-wrapper">\Pico::setConfig()</span></a></dd>
- <dd><a href="../classes/Pico.html#method_loadConfig"><span class="namespace-wrapper">\Pico::loadConfig()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getRequestUrl" name="method_getRequestUrl" class="anchor"></a>
- <article class="method">
- <h3 class="public ">getRequestUrl()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getRequestUrl() : string|null</pre>
- <p><em>Returns the URL where a user requested the page</em></p>
-
-
-
- <h4>Returns</h4>
- string|null
- — <p>request URL</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_evaluateRequestUrl"><span class="namespace-wrapper">\Pico::evaluateRequestUrl()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getRequestFile" name="method_getRequestFile" class="anchor"></a>
- <article class="method">
- <h3 class="public ">getRequestFile()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getRequestFile() : string|null</pre>
- <p><em>Returns the absolute path to the content file to serve</em></p>
-
-
-
- <h4>Returns</h4>
- string|null
- — <p>file path</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_discoverRequestFile"><span class="namespace-wrapper">\Pico::discoverRequestFile()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_loadFileContent" name="method_loadFileContent" class="anchor"></a>
- <article class="method">
- <h3 class="public ">loadFileContent()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">loadFileContent(string <span class="argument">$file</span>) : string</pre>
- <p><em>Returns the raw contents of a file</em></p>
-
- <h4>Parameters</h4>
- <table class="table table-condensed table-hover">
- <tr>
- <td>string</td>
- <td>$file </td>
- <td><p>file path</p></td>
- </tr>
- </table>
-
-
- <h4>Returns</h4>
- string
- — <p>raw contents of the file</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getRawContent"><span class="namespace-wrapper">\Pico::getRawContent()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_load404Content" name="method_load404Content" class="anchor"></a>
- <article class="method">
- <h3 class="public ">load404Content()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">load404Content(string <span class="argument">$file</span>) : string</pre>
- <p><em>Returns the raw contents of the first found 404 file when traversing
- up from the directory the requested file is in</em></p>
-
- <h4>Parameters</h4>
- <table class="table table-condensed table-hover">
- <tr>
- <td>string</td>
- <td>$file </td>
- <td><p>path to requested (but not existing) file</p></td>
- </tr>
- </table>
-
- <h4>Throws</h4>
- <dl>
- <dt>\RuntimeException</dt>
- <dd><p>thrown when no suitable 404 file is found</p></dd>
- </dl>
-
- <h4>Returns</h4>
- string
- — <p>raw contents of the 404 file</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getRawContent"><span class="namespace-wrapper">\Pico::getRawContent()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getRawContent" name="method_getRawContent" class="anchor"></a>
- <article class="method">
- <h3 class="public ">getRawContent()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getRawContent() : string|null</pre>
- <p><em>Returns the raw contents, either of the requested or the 404 file</em></p>
-
-
-
- <h4>Returns</h4>
- string|null
- — <p>raw contents</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_loadFileContent"><span class="namespace-wrapper">\Pico::loadFileContent()</span></a></dd>
- <dd><a href="../classes/Pico.html#method_load404Content"><span class="namespace-wrapper">\Pico::load404Content()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getMetaHeaders" name="method_getMetaHeaders" class="anchor"></a>
- <article class="method">
- <h3 class="public ">getMetaHeaders()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getMetaHeaders() : array<mixed,string></pre>
- <p><em>Returns known meta headers and triggers the onMetaHeaders event</em></p>
- <p>Heads up! Calling this method triggers the <code>onMetaHeaders</code> event.
- Keep this in mind to prevent a infinite loop!</p>
-
-
- <h4>Returns</h4>
- array<mixed,string>
- — <p>known meta headers; the array value specifies the
- YAML key to search for, the array key is later used to access the
- found value</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_parseFileMeta" name="method_parseFileMeta" class="anchor"></a>
- <article class="method">
- <h3 class="public ">parseFileMeta()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">parseFileMeta(string <span class="argument">$rawContent</span>, array<mixed,string> <span class="argument">$headers</span>) : array</pre>
- <p><em>Parses the file meta from raw file contents</em></p>
- <p>Meta data MUST start on the first line of the file, either opened and
- closed by <code>---</code> or C-style block comments (deprecated). The headers are
- parsed by the YAML component of the Symfony project, keys are lowered.
- If you're a plugin developer, you MUST register new headers during the
- <code>onMetaHeaders</code> event first. The implicit availability of headers is
- for users and pure (!) theme developers ONLY.</p>
- <h4>Parameters</h4>
- <table class="table table-condensed table-hover">
- <tr>
- <td>string</td>
- <td>$rawContent </td>
- <td><p>the raw file contents</p></td>
- </tr>
- <tr>
- <td>array<mixed,string></td>
- <td>$headers </td>
- <td><p>known meta headers</p></td>
- </tr>
- </table>
-
-
- <h4>Returns</h4>
- array
- — <p>parsed meta data</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getFileMeta"><span class="namespace-wrapper">\Pico::getFileMeta()</span></a></dd>
- <dd><a href=""><span class="namespace-wrapper">\<http://symfony.com/doc/current/components/yaml/introduction.html></span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getFileMeta" name="method_getFileMeta" class="anchor"></a>
- <article class="method">
- <h3 class="public ">getFileMeta()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getFileMeta() : array|null</pre>
- <p><em>Returns the parsed meta data of the requested page</em></p>
-
-
-
- <h4>Returns</h4>
- array|null
- — <p>parsed meta data</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_parseFileMeta"><span class="namespace-wrapper">\Pico::parseFileMeta()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_prepareFileContent" name="method_prepareFileContent" class="anchor"></a>
- <article class="method">
- <h3 class="public ">prepareFileContent()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">prepareFileContent(string <span class="argument">$rawContent</span>) : string</pre>
- <p><em>Applies some static preparations to the raw contents of a page,
- e.g. removing the meta header and replacing %base_url%</em></p>
-
- <h4>Parameters</h4>
- <table class="table table-condensed table-hover">
- <tr>
- <td>string</td>
- <td>$rawContent </td>
- <td><p>raw contents of a page</p></td>
- </tr>
- </table>
-
-
- <h4>Returns</h4>
- string
- — <p>contents prepared for parsing</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_parseFileContent"><span class="namespace-wrapper">\Pico::parseFileContent()</span></a></dd>
- <dd><a href="../classes/Pico.html#method_getFileContent"><span class="namespace-wrapper">\Pico::getFileContent()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_parseFileContent" name="method_parseFileContent" class="anchor"></a>
- <article class="method">
- <h3 class="public ">parseFileContent()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">parseFileContent(string <span class="argument">$content</span>) : string</pre>
- <p><em>Parses the contents of a page using ParsedownExtra</em></p>
-
- <h4>Parameters</h4>
- <table class="table table-condensed table-hover">
- <tr>
- <td>string</td>
- <td>$content </td>
- <td><p>raw contents of a page (Markdown)</p></td>
- </tr>
- </table>
-
-
- <h4>Returns</h4>
- string
- — <p>parsed contents (HTML)</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_prepareFileContent"><span class="namespace-wrapper">\Pico::prepareFileContent()</span></a></dd>
- <dd><a href="../classes/Pico.html#method_getFileContent"><span class="namespace-wrapper">\Pico::getFileContent()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getFileContent" name="method_getFileContent" class="anchor"></a>
- <article class="method">
- <h3 class="public ">getFileContent()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getFileContent() : string|null</pre>
- <p><em>Returns the cached contents of the requested page</em></p>
-
-
-
- <h4>Returns</h4>
- string|null
- — <p>parsed contents</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_prepareFileContent"><span class="namespace-wrapper">\Pico::prepareFileContent()</span></a></dd>
- <dd><a href="../classes/Pico.html#method_parseFileContent"><span class="namespace-wrapper">\Pico::parseFileContent()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getPages" name="method_getPages" class="anchor"></a>
- <article class="method">
- <h3 class="public ">getPages()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getPages() : array|null</pre>
- <p><em>Returns the list of known pages</em></p>
-
-
-
- <h4>Returns</h4>
- array|null
- — <p>the data of all pages</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_readPages"><span class="namespace-wrapper">\Pico::readPages()</span></a></dd>
- <dd><a href="../classes/Pico.html#method_sortPages"><span class="namespace-wrapper">\Pico::sortPages()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getCurrentPage" name="method_getCurrentPage" class="anchor"></a>
- <article class="method">
- <h3 class="public ">getCurrentPage()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getCurrentPage() : array|null</pre>
- <p><em>Returns the data of the requested page</em></p>
-
-
-
- <h4>Returns</h4>
- array|null
- — <p>page data</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_discoverCurrentPage"><span class="namespace-wrapper">\Pico::discoverCurrentPage()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getPreviousPage" name="method_getPreviousPage" class="anchor"></a>
- <article class="method">
- <h3 class="public ">getPreviousPage()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getPreviousPage() : array|null</pre>
- <p><em>Returns the data of the previous page relative to the page being served</em></p>
-
-
-
- <h4>Returns</h4>
- array|null
- — <p>page data</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_discoverCurrentPage"><span class="namespace-wrapper">\Pico::discoverCurrentPage()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getNextPage" name="method_getNextPage" class="anchor"></a>
- <article class="method">
- <h3 class="public ">getNextPage()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getNextPage() : array|null</pre>
- <p><em>Returns the data of the next page relative to the page being served</em></p>
-
-
-
- <h4>Returns</h4>
- array|null
- — <p>page data</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_discoverCurrentPage"><span class="namespace-wrapper">\Pico::discoverCurrentPage()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getTwig" name="method_getTwig" class="anchor"></a>
- <article class="method">
- <h3 class="public ">getTwig()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getTwig() : \Twig_Environment|null</pre>
- <p><em>Returns the twig template engine</em></p>
-
-
-
- <h4>Returns</h4>
- \Twig_Environment|null
- — <p>twig template engine</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_registerTwig"><span class="namespace-wrapper">\Pico::registerTwig()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getBaseUrl" name="method_getBaseUrl" class="anchor"></a>
- <article class="method">
- <h3 class="public ">getBaseUrl()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getBaseUrl() : string</pre>
- <p><em>Returns the base URL of this Pico instance</em></p>
-
-
-
- <h4>Returns</h4>
- string
- — <p>the base url</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_isUrlRewritingEnabled" name="method_isUrlRewritingEnabled" class="anchor"></a>
- <article class="method">
- <h3 class="public ">isUrlRewritingEnabled()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">isUrlRewritingEnabled() : boolean</pre>
- <p><em>Returns true if URL rewriting is enabled</em></p>
-
-
-
- <h4>Returns</h4>
- boolean
- — <p>true if URL rewriting is enabled, false otherwise</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getPageUrl" name="method_getPageUrl" class="anchor"></a>
- <article class="method">
- <h3 class="public ">getPageUrl()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getPageUrl(string <span class="argument">$page</span>) : string</pre>
- <p><em>Returns the URL to a given page</em></p>
-
- <h4>Parameters</h4>
- <table class="table table-condensed table-hover">
- <tr>
- <td>string</td>
- <td>$page </td>
- <td><p>identifier of the page to link to</p></td>
- </tr>
- </table>
-
-
- <h4>Returns</h4>
- string
- — <p>URL</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_loadPlugins" name="method_loadPlugins" class="anchor"></a>
- <article class="method">
- <h3 class="protected ">loadPlugins()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">loadPlugins() : void</pre>
- <p><em>Loads plugins from Pico::$pluginsDir in alphabetical order</em></p>
- <p>Plugin files may be prefixed by a number (e.g. 00-PicoDeprecated.php)
- to indicate their processing order. You MUST NOT use prefixes between
- 00 and 19 (reserved for built-in plugins).</p>
-
- <h4>Throws</h4>
- <dl>
- <dt>\RuntimeException</dt>
- <dd><p>thrown when a plugin couldn't be loaded</p></dd>
- </dl>
-
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getPlugin"><span class="namespace-wrapper">\Pico::getPlugin()</span></a></dd>
- <dd><a href="../classes/Pico.html#method_getPlugins"><span class="namespace-wrapper">\Pico::getPlugins()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_loadConfig" name="method_loadConfig" class="anchor"></a>
- <article class="method">
- <h3 class="protected ">loadConfig()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">loadConfig() : void</pre>
- <p><em>Loads the config.php from Pico::$configDir</em></p>
-
-
-
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_setConfig"><span class="namespace-wrapper">\Pico::setConfig()</span></a></dd>
- <dd><a href="../classes/Pico.html#method_getConfig"><span class="namespace-wrapper">\Pico::getConfig()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_evaluateRequestUrl" name="method_evaluateRequestUrl" class="anchor"></a>
- <article class="method">
- <h3 class="protected ">evaluateRequestUrl()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">evaluateRequestUrl() : void</pre>
- <p><em>Evaluates the requested URL</em></p>
- <p>Pico 1.0 uses the <code>QUERY_STRING</code> routing method (e.g. <code>/pico/?sub/page</code>)
- to support SEO-like URLs out-of-the-box with any webserver. You can
- still setup URL rewriting (e.g. using <code>mod_rewrite</code> on Apache) to
- basically remove the <code>?</code> from URLs, but your rewritten URLs must follow
- the new <code>QUERY_STRING</code> principles. URL rewriting requires some special
- configuration on your webserver, but this should be "basic work" for
- any webmaster...</p>
- <p>Pico 0.9 and older required Apache with <code>mod_rewrite</code> enabled, thus old
- plugins, templates and contents may require you to enable URL rewriting
- to work. If you're upgrading from Pico 0.9, you will probably have to
- update your rewriting rules.</p>
- <p>We recommend you to use the <code>link</code> filter in templates to create
- internal links, e.g. <code>{{ "sub/page"|link }}</code> is equivalent to
- <code>{{ base_url }}sub/page</code>. In content files you can still use the
- <code>%base_url%</code> variable; e.g. <code>%base_url%?sub/page</code> will be automatically
- replaced accordingly.</p>
-
-
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getRequestUrl"><span class="namespace-wrapper">\Pico::getRequestUrl()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_discoverRequestFile" name="method_discoverRequestFile" class="anchor"></a>
- <article class="method">
- <h3 class="protected ">discoverRequestFile()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">discoverRequestFile() : void</pre>
- <p><em>Uses the request URL to discover the content file to serve</em></p>
-
-
-
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getRequestFile"><span class="namespace-wrapper">\Pico::getRequestFile()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_readPages" name="method_readPages" class="anchor"></a>
- <article class="method">
- <h3 class="protected ">readPages()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">readPages() : void</pre>
- <p><em>Reads the data of all pages known to Pico</em></p>
- <p>The page data will be an array containing the following values:</p>
- <pre>
- +----------------+--------+------------------------------------------+
- | Array key | Type | Description |
- +----------------+--------+------------------------------------------+
- | id | string | relative path to the content file |
- | url | string | URL to the page |
- | title | string | title of the page (YAML header) |
- | description | string | description of the page (YAML header) |
- | author | string | author of the page (YAML header) |
- | time | string | timestamp derived from the Date header |
- | date | string | date of the page (YAML header) |
- | date_formatted | string | formatted date of the page |
- | raw_content | string | raw, not yet parsed contents of the page |
- | meta | string | parsed meta data of the page |
- +----------------+--------+------------------------------------------+
- </pre>
-
-
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_sortPages"><span class="namespace-wrapper">\Pico::sortPages()</span></a></dd>
- <dd><a href="../classes/Pico.html#method_getPages"><span class="namespace-wrapper">\Pico::getPages()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_sortPages" name="method_sortPages" class="anchor"></a>
- <article class="method">
- <h3 class="protected ">sortPages()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">sortPages() : void</pre>
- <p><em>Sorts all pages known to Pico</em></p>
-
-
-
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_readPages"><span class="namespace-wrapper">\Pico::readPages()</span></a></dd>
- <dd><a href="../classes/Pico.html#method_getPages"><span class="namespace-wrapper">\Pico::getPages()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_discoverCurrentPage" name="method_discoverCurrentPage" class="anchor"></a>
- <article class="method">
- <h3 class="protected ">discoverCurrentPage()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">discoverCurrentPage() : void</pre>
- <p><em>Walks through the list of known pages and discovers the requested page
- as well as the previous and next page relative to it</em></p>
-
-
-
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getCurrentPage"><span class="namespace-wrapper">\Pico::getCurrentPage()</span></a></dd>
- <dd><a href="../classes/Pico.html#method_getPreviousPage"><span class="namespace-wrapper">\Pico::getPreviousPage()</span></a></dd>
- <dd><a href="../classes/Pico.html#method_getNextPage"><span class="namespace-wrapper">\Pico::getNextPage()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_registerTwig" name="method_registerTwig" class="anchor"></a>
- <article class="method">
- <h3 class="protected ">registerTwig()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">registerTwig() : void</pre>
- <p><em>Registers the twig template engine</em></p>
-
-
-
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/Pico.html#method_getTwig"><span class="namespace-wrapper">\Pico::getTwig()</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getTwigVariables" name="method_getTwigVariables" class="anchor"></a>
- <article class="method">
- <h3 class="protected ">getTwigVariables()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getTwigVariables() : array<mixed,mixed></pre>
- <p><em>Returns the variables passed to the template</em></p>
- <p>URLs and paths (namely <code>base_dir</code>, <code>base_url</code>, <code>theme_dir</code> and
- <code>theme_url</code>) don't add a trailing slash for historic reasons.</p>
-
-
- <h4>Returns</h4>
- array<mixed,mixed>
- — <p>template variables</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getFiles" name="method_getFiles" class="anchor"></a>
- <article class="method">
- <h3 class="protected ">getFiles()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getFiles(string <span class="argument">$directory</span>, string <span class="argument">$fileExtension = ''</span>, integer <span class="argument">$order = self::SORT_ASC</span>) : array</pre>
- <p><em>Recursively walks through a directory and returns all containing files
- matching the specified file extension</em></p>
-
- <h4>Parameters</h4>
- <table class="table table-condensed table-hover">
- <tr>
- <td>string</td>
- <td>$directory </td>
- <td><p>start directory</p></td>
- </tr>
- <tr>
- <td>string</td>
- <td>$fileExtension </td>
- <td><p>return files with the given file extension
- only (optional)</p></td>
- </tr>
- <tr>
- <td>integer</td>
- <td>$order </td>
- <td><p>specify whether and how files should be
- sorted; use Pico::SORT_ASC for a alphabetical ascending order (this
- is the default behaviour), Pico::SORT_DESC for a descending order
- or Pico::SORT_NONE to leave the result unsorted</p></td>
- </tr>
- </table>
-
-
- <h4>Returns</h4>
- array
- — <p>list of found files</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_getAbsolutePath" name="method_getAbsolutePath" class="anchor"></a>
- <article class="method">
- <h3 class="protected ">getAbsolutePath()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">getAbsolutePath(string <span class="argument">$path</span>) : string</pre>
- <p><em>Makes a relative path absolute to Picos root dir</em></p>
- <p>This method also guarantees a trailing slash.</p>
- <h4>Parameters</h4>
- <table class="table table-condensed table-hover">
- <tr>
- <td>string</td>
- <td>$path </td>
- <td><p>relative or absolute path</p></td>
- </tr>
- </table>
-
-
- <h4>Returns</h4>
- string
- — <p>absolute path</p>
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- <div class="row-fluid">
- <div class="span8 content class">
- <a id="method_triggerEvent" name="method_triggerEvent" class="anchor"></a>
- <article class="method">
- <h3 class="protected ">triggerEvent()</h3>
- <a href="#source-view" role="button" class="pull-right btn" data-toggle="modal" style="font-size: 1.1em; padding: 9px 14px"><i class="icon-code"></i></a>
- <pre class="signature" style="margin-right: 54px;">triggerEvent(string <span class="argument">$eventName</span>, array <span class="argument">$params = array()</span>) : void</pre>
- <p><em>Triggers events on plugins which implement PicoPluginInterface</em></p>
- <p>Deprecated events (as used by plugins not implementing
- \IPocPlugin) are triggered by \PicoDeprecated.</p>
- <h4>Parameters</h4>
- <table class="table table-condensed table-hover">
- <tr>
- <td>string</td>
- <td>$eventName </td>
- <td><p>name of the event to trigger</p></td>
- </tr>
- <tr>
- <td>array</td>
- <td>$params </td>
- <td><p>optional parameters to pass</p></td>
- </tr>
- </table>
-
-
-
- </article>
- </div>
- <aside class="span4 detailsbar">
- <h1><i class="icon-arrow-down"></i></h1>
- <dl>
- <dt>See also</dt>
- <dd><a href="../classes/PicoPluginInterface.html"><span class="namespace-wrapper">\PicoPluginInterface</span></a></dd>
- <dd><a href="../classes/AbstractPicoPlugin.html"><span class="namespace-wrapper">\AbstractPicoPlugin</span></a></dd>
- <dd><a href="../classes/DummyPlugin.html"><span class="namespace-wrapper">\DummyPlugin</span></a></dd>
- </dl>
- <h2>Tags</h2>
- <table class="table table-condensed">
- <tr><td colspan="2"><em>None found</em></td></tr>
- </table>
- </aside>
- </div>
- </div>
- </section>
- <div id="source-view" class="modal hide fade" tabindex="-1" role="dialog" aria-labelledby="source-view-label" aria-hidden="true">
- <div class="modal-header">
- <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
- <h3 id="source-view-label">Pico.php</h3>
- </div>
- <div class="modal-body">
- <pre data-src="../files/lib/Pico.php.txt" class="language-php line-numbers"></pre>
- </div>
- </div>
- <footer class="row-fluid">
- <section class="span10 offset2">
- <section class="row-fluid">
- <section class="span10 offset1">
- <section class="row-fluid footer-sections">
- <section class="span4">
- <h1><i class="icon-code"></i></h1>
- <div>
- <ul>
- </ul>
- </div>
- </section>
- <section class="span4">
- <h1><i class="icon-bar-chart"></i></h1>
- <div>
- <ul>
- <li><a href="../graphs/class.html">Class Hierarchy Diagram</a></li>
- </ul>
- </div>
- </section>
- <section class="span4">
- <h1><i class="icon-pushpin"></i></h1>
- <div>
- <ul>
- <li><a href="../reports/errors.html">Errors</a></li>
- <li><a href="../reports/markers.html">Markers</a></li>
- </ul>
- </div>
- </section>
- </section>
- </section>
- </section>
- <section class="row-fluid">
- <section class="span10 offset1">
- <hr />
- Documentation is powered by <a href="http://www.phpdoc.org/">phpDocumentor </a> and authored
- on November 3rd, 2015 at 16:05.
- </section>
- </section>
- </section>
- </footer>
- </div>
- </body>
- </html>
|