Commits

Greg Slepak committed 3079fce

updated dragonfly_routes

Comments (0)

Files changed (3)

Add a comment to this file

example-site/includes/images/rails_rest.png

Old
Old image
New
New image
Add a comment to this file

example-site/includes/images/rails_rest_fix.png

Old
Old image
New
New image

example-site/views/dragonfly_views.html

 		<h1>Templates</h1>
 		<p class="extract">In Dragonfly, templates are files that have newLISP code embedded in them. This code is evaluated server-side, generating a final document that's presented to visitors.</p>
 
-		<h2>The </h2>
-		<p>Example: open Your favorite text-editor and enter the following:</p>
-		<pre class="code">Hello World</pre>
-		<p>Save the file as "hello" into Your views directory. Now open Your browser and navigate to <a href="http://www.example-site.com/hello">example-site.com/hello</a>. That's it!</p>
-		<p class="info"><b>INFORMATION</b><br/>You can put nearly everything into views: (X)HTML, Javascript, newLISP code.</p>
-		<p class="config"><b>CONFIGURATION</b><br/>If VIEW_EXTENSION is ".html" for example, then when example-site.com/hello is called Dragonfly will search for a "hello.html" file in the VIEWS_PATH. It also applies to the partials, too.</p>
+		<h2>The importance of routes</h2>
+		<p>
+			
+		</p>
+		
+		<h2>View configuration</h2>
+		<p>
+			
+		</p>
+		
+		<h3 class="param">VIEWS_PATH</h3>
+		<p>Default value: <span class="code"><b>(string DOCUMENT_ROOT "/views")</b></span></p>
+		<p>
+			The location of views (for use with 'display-view' function).
+		</p>
+		
+		<h3 class="param">PARTIALS_PATH</h3>
+		<p>Default value: <span class="code"><b>(string DOCUMENT_ROOT "/views/partials")</b></span></p>
+		<p>
+			The location of partials (for use with 'display-partial' function).
+		</p>
+		
+		<h3 class="param">DEFAULT_VIEW</h3>
+		<p>Default value: <span class="code"><b>"welcome"</b></span></p>
+		<p>
+			The default view (when a user visits '/') sans file extension.
+		</p>
+		
+		<h3 class="param">VIEW_EXTENSION</h3>
+		<p>Default value: <span class="code"><b>".html"</b></span></p>
 
 		<h2>How to call functions inside a view</h2>
 		<pre class="code">&lt;% (benchmark-result) %&gt;</pre>
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.