summaryrefslogtreecommitdiffabout
authorMichael Krelin <hacker@klever.net>2005-02-03 00:17:58 (UTC)
committer Michael Krelin <hacker@klever.net>2005-02-03 00:17:58 (UTC)
commitd379841850daab4693d596784b790b13e20e3a03 (patch) (unidiff)
treeeafa246cd99308ea349aef90a708ef9f6d7a0418
parent870963df2dac72e433fd7f94cd1cccc8cd6ea2d0 (diff)
downloadsitecing-d379841850daab4693d596784b790b13e20e3a03.zip
sitecing-d379841850daab4693d596784b790b13e20e3a03.tar.gz
sitecing-d379841850daab4693d596784b790b13e20e3a03.tar.bz2
1. added a 'browse-through' navigation
2. improved performance by passing -flush to FastCgiExternalServer 3. emphasized links in text
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--conf/httpd.conf.in2
-rw-r--r--htdocs/ancestry/layout.chtml24
-rw-r--r--htdocs/exceptions/compile.chtml2
-rw-r--r--htdocs/exceptions/index.chtml4
-rw-r--r--htdocs/exceptions/preprocess.chtml2
-rw-r--r--htdocs/exceptions/runtime.chtml2
-rw-r--r--htdocs/index.chtml3
-rw-r--r--htdocs/simple.chtml2
-rw-r--r--htdocs/sources.chtml1
-rw-r--r--htdocs/style.css28
10 files changed, 69 insertions, 1 deletions
diff --git a/conf/httpd.conf.in b/conf/httpd.conf.in
index 5910620..2184627 100644
--- a/conf/httpd.conf.in
+++ b/conf/httpd.conf.in
@@ -1,9 +1,9 @@
1FastCgiExternalServer @web_run_root@/fastcgi-bin/site-c-ing -socket @web_run_root@/run/sitecing-socket 1FastCgiExternalServer @web_run_root@/fastcgi-bin/site-c-ing -socket @web_run_root@/run/sitecing-socket -flush
2<VirtualHost *:80> 2<VirtualHost *:80>
3 ServerName @v_hostname@ 3 ServerName @v_hostname@
4 DocumentRoot @web_src_root@/htdocs 4 DocumentRoot @web_src_root@/htdocs
5 <Directory @web_src_root@/htdocs> 5 <Directory @web_src_root@/htdocs>
6 AllowOverride All 6 AllowOverride All
7 allow from all 7 allow from all
8 </Directory> 8 </Directory>
9 <DirectoryMatch /.svn/> 9 <DirectoryMatch /.svn/>
diff --git a/htdocs/ancestry/layout.chtml b/htdocs/ancestry/layout.chtml
index 6147d37..0c167bc 100644
--- a/htdocs/ancestry/layout.chtml
+++ b/htdocs/ancestry/layout.chtml
@@ -1,22 +1,46 @@
1% html(); return; /* vim:set ft=sitecing: */ 1% html(); return; /* vim:set ft=sitecing: */
2%%derive page = "/ancestry/page.chtml"; 2%%derive page = "/ancestry/page.chtml";
3<%decl>
4 #define PN_PREV(h,d,t) urlPrev=h; descPrev=d; titlePrev=t;
5 #define PN_NEXT(h,d,t) urlNext=h; descNext=d; titleNext=t;
6</%decl>
7%%impl #include <sitecing/util.h>
3%%impl #include "acconfig.h" 8%%impl #include "acconfig.h"
4%%var bool b_svn = false; 9%%var bool b_svn = false;
10%%var std::string urlPrev;
11%%var std::string descPrev;
12%%var std::string titlePrev;
13%%var std::string urlNext;
14%%var std::string descNext;
15%%var std::string titleNext;
5<%constructor> 16<%constructor>
6 if(strstr(PACKAGE_STRING,"svn")) 17 if(strstr(PACKAGE_STRING,"svn"))
7 b_svn = true; 18 b_svn = true;
8</%constructor> 19</%constructor>
20<%method void prevnext() %>
21% if(urlPrev.empty() && urlNext.empty()) return;
22% if(descPrev.empty() && descNext.empty()) return;
23 <div class="prevnext">
24% if(!(urlPrev.empty() || descPrev.empty())) {
25 <a class="prevnext-prev" href="<% urlPrev %>" title="<% sitecing::html_escape(titlePrev.empty()?descPrev:titlePrev) %>"><% sitecing::html_escape(descPrev) %></a>
26% }
27% if(!(urlNext.empty() || descNext.empty())) {
28 <a class="prevnext-next" href="<% urlNext %>" title="<% sitecing::html_escape(titleNext.empty()?descNext:titleNext) %>"><% sitecing::html_escape(descNext) %></a>
29% }
30 </div>
31</%method>
9<%method void body() %> 32<%method void body() %>
10 <div id="content"> 33 <div id="content">
11 <%code> 34 <%code>
12 if(!access(WEB_RUN_ROOT "/conf/banner_top",R_OK)) { 35 if(!access(WEB_RUN_ROOT "/conf/banner_top",R_OK)) {
13 pass_file_through(WEB_RUN_ROOT "/conf/banner_top"); 36 pass_file_through(WEB_RUN_ROOT "/conf/banner_top");
14 } 37 }
38 prevnext();
15 content(); 39 content();
16 if(b_strict && !access(WEB_RUN_ROOT "/conf/banner_bottom",R_OK)) { 40 if(b_strict && !access(WEB_RUN_ROOT "/conf/banner_bottom",R_OK)) {
17 pass_file_through(WEB_RUN_ROOT "/conf/banner_bottom"); 41 pass_file_through(WEB_RUN_ROOT "/conf/banner_bottom");
18 } 42 }
19 </%code> 43 </%code>
20 </div> 44 </div>
21 <div id="sidepanel"> 45 <div id="sidepanel">
22% sidepanel(); 46% sidepanel();
diff --git a/htdocs/exceptions/compile.chtml b/htdocs/exceptions/compile.chtml
index aa4c8df..68dd034 100644
--- a/htdocs/exceptions/compile.chtml
+++ b/htdocs/exceptions/compile.chtml
@@ -1,12 +1,14 @@
1% html(); return; /* vim:set ft=sitecing: */ 1% html(); return; /* vim:set ft=sitecing: */
2%%derive layout = "/ancestry/layout.chtml"; 2%%derive layout = "/ancestry/layout.chtml";
3<%constructor> 3<%constructor>
4 b_strict = false; 4 b_strict = false;
5 PN_PREV("/exceptions/preprocess","preprocess","preprocessing errors");
6 PN_NEXT("/exceptions/runtime","runtime","runtime exceptions");
5</%constructor> 7</%constructor>
6<%codemethod string title() %> 8<%codemethod string title() %>
7 return "compile-time exceptions handling"; 9 return "compile-time exceptions handling";
8</%codemethod> 10</%codemethod>
9<%method void content() %> 11<%method void content() %>
10 <h1>site-C-ing compile-time exception handling</h1> 12 <h1>site-C-ing compile-time exception handling</h1>
11 <p> 13 <p>
12 Similar to <a href="/exceptions/preprocess">preprocessing exceptions</a> 14 Similar to <a href="/exceptions/preprocess">preprocessing exceptions</a>
diff --git a/htdocs/exceptions/index.chtml b/htdocs/exceptions/index.chtml
index cc0ed8a..e66620a 100644
--- a/htdocs/exceptions/index.chtml
+++ b/htdocs/exceptions/index.chtml
@@ -1,10 +1,14 @@
1% html(); return; /* vim:set ft=sitecing: */ 1% html(); return; /* vim:set ft=sitecing: */
2%%derive layout = "/ancestry/layout.chtml"; 2%%derive layout = "/ancestry/layout.chtml";
3<%constructor>
4 PN_PREV("/simple","simple page","building a really simple page");
5 PN_NEXT("/exceptions/preprocess","preprocess","preprocessing errors");
6</%constructor>
3<%codemethod string title() %> 7<%codemethod string title() %>
4 return "exceptions handling"; 8 return "exceptions handling";
5</%codemethod> 9</%codemethod>
6<%method void content() %> 10<%method void content() %>
7 <h1>site-C-ing exception handling</h1> 11 <h1>site-C-ing exception handling</h1>
8 <p> 12 <p>
9 The purpose of this section is to give an overview of the <em>site-C-ing</em> 13 The purpose of this section is to give an overview of the <em>site-C-ing</em>
10 exception handling mechanism. Before the web visitor can see the page each 14 exception handling mechanism. Before the web visitor can see the page each
diff --git a/htdocs/exceptions/preprocess.chtml b/htdocs/exceptions/preprocess.chtml
index 8516139..88b8741 100644
--- a/htdocs/exceptions/preprocess.chtml
+++ b/htdocs/exceptions/preprocess.chtml
@@ -1,12 +1,14 @@
1% html(); return; /* vim:set ft=sitecing: */ 1% html(); return; /* vim:set ft=sitecing: */
2%%derive layout = "/ancestry/layout.chtml"; 2%%derive layout = "/ancestry/layout.chtml";
3<%constructor> 3<%constructor>
4 b_strict = false; 4 b_strict = false;
5 PN_PREV("/exceptions","exceptions","exception handling overview");
6 PN_NEXT("/exceptions/compile","compile-time","compile-time errors");
5</%constructor> 7</%constructor>
6<%codemethod string title() %> 8<%codemethod string title() %>
7 return "preprocessor exceptions handling"; 9 return "preprocessor exceptions handling";
8</%codemethod> 10</%codemethod>
9<%method void content() %> 11<%method void content() %>
10 <h1>site-C-ing preprocessor exception handling</h1> 12 <h1>site-C-ing preprocessor exception handling</h1>
11 <p> 13 <p>
12 It was one of those days when you just can't type right and can't think of 14 It was one of those days when you just can't type right and can't think of
diff --git a/htdocs/exceptions/runtime.chtml b/htdocs/exceptions/runtime.chtml
index d0a8e14..9a72afd 100644
--- a/htdocs/exceptions/runtime.chtml
+++ b/htdocs/exceptions/runtime.chtml
@@ -1,12 +1,14 @@
1% html(); return; /* vim:set ft=sitecing: */ 1% html(); return; /* vim:set ft=sitecing: */
2%%derive layout = "/ancestry/layout.chtml"; 2%%derive layout = "/ancestry/layout.chtml";
3<%constructor> 3<%constructor>
4 b_strict = false; 4 b_strict = false;
5 PN_PREV("/exceptions/compile","compile-time","compile-time errors");
6 PN_NEXT("/sources","sources","source browser");
5</%constructor> 7</%constructor>
6<%codemethod string title() %> 8<%codemethod string title() %>
7 return "runtime exceptions handling"; 9 return "runtime exceptions handling";
8</%codemethod> 10</%codemethod>
9<%method void content() %> 11<%method void content() %>
10 <h1>site-C-ing runtime exception handling</h1> 12 <h1>site-C-ing runtime exception handling</h1>
11 <p> 13 <p>
12 The component may throw an exception while executing and the 14 The component may throw an exception while executing and the
diff --git a/htdocs/index.chtml b/htdocs/index.chtml
index aa0979a..e8cedda 100644
--- a/htdocs/index.chtml
+++ b/htdocs/index.chtml
@@ -1,10 +1,13 @@
1% html(); return; /* vim:set ft=sitecing: */ 1% html(); return; /* vim:set ft=sitecing: */
2%%derive layout = "/ancestry/layout.chtml"; 2%%derive layout = "/ancestry/layout.chtml";
3<%constructor>
4 PN_NEXT("/simple","simple page","building a really simple page");
5</%constructor>
3<%codemethod string title() %> 6<%codemethod string title() %>
4 return "introduction"; 7 return "introduction";
5</%codemethod> 8</%codemethod>
6<%method void content() %> 9<%method void content() %>
7 <h1>introduction to site-C-ing</h1> 10 <h1>introduction to site-C-ing</h1>
8 <p> 11 <p>
9 This is a sample site, which is supposed to demonstrate <em>site-C-ing</em> 12 This is a sample site, which is supposed to demonstrate <em>site-C-ing</em>
10 features. Since the <em>site-C-ing</em> is still at the early stages of 13 features. Since the <em>site-C-ing</em> is still at the early stages of
diff --git a/htdocs/simple.chtml b/htdocs/simple.chtml
index 9900f00..845b840 100644
--- a/htdocs/simple.chtml
+++ b/htdocs/simple.chtml
@@ -1,12 +1,14 @@
1% html(); return; /* vim:set ft=sitecing: */ 1% html(); return; /* vim:set ft=sitecing: */
2%%derive layout = "/ancestry/layout.chtml"; 2%%derive layout = "/ancestry/layout.chtml";
3<%constructor> 3<%constructor>
4 b_strict = false; 4 b_strict = false;
5 PN_PREV("/","overview","introduction to site-C-ing");
6 PN_NEXT("/exceptions","exceptions","exception handling overview");
5</%constructor> 7</%constructor>
6<%codemethod string title() %> 8<%codemethod string title() %>
7 return "simple page"; 9 return "simple page";
8</%codemethod> 10</%codemethod>
9<%method void content() %> 11<%method void content() %>
10 <h1>building a really simple page</h1> 12 <h1>building a really simple page</h1>
11 <p> 13 <p>
12 Building a really simple page is really simple. I will not go into much detail 14 Building a really simple page is really simple. I will not go into much detail
diff --git a/htdocs/sources.chtml b/htdocs/sources.chtml
index b1eeed3..6341f49 100644
--- a/htdocs/sources.chtml
+++ b/htdocs/sources.chtml
@@ -1,16 +1,17 @@
1% html(); return; /* vim:set ft=sitecing: */ 1% html(); return; /* vim:set ft=sitecing: */
2%%derive layout = "/ancestry/layout.chtml"; 2%%derive layout = "/ancestry/layout.chtml";
3%%derive sources = "/ancestry/sources.chtml"; 3%%derive sources = "/ancestry/sources.chtml";
4<%impl> 4<%impl>
5 #include <sitecing/sitecing_util.h> 5 #include <sitecing/sitecing_util.h>
6</%impl> 6</%impl>
7<%constructor> 7<%constructor>
8 b_strict = false; 8 b_strict = false;
9 PN_PREV("/exceptions/runtime","runtime","runtime exceptions");
9</%constructor> 10</%constructor>
10<%codemethod string title() %> 11<%codemethod string title() %>
11 return "runtime exceptions handling"; 12 return "runtime exceptions handling";
12</%codemethod> 13</%codemethod>
13<%method void content() %> 14<%method void content() %>
14 <h1>browse this site sources</h1> 15 <h1>browse this site sources</h1>
15 16
16 <ul class="sourcebrowser"> 17 <ul class="sourcebrowser">
diff --git a/htdocs/style.css b/htdocs/style.css
index 3ab1b6f..83e308f 100644
--- a/htdocs/style.css
+++ b/htdocs/style.css
@@ -111,16 +111,20 @@ div#sidepanel div.copyright {
111} 111}
112 112
113div#content h1 { 113div#content h1 {
114 font-size: 140%; 114 font-size: 140%;
115 color: gray; 115 color: gray;
116 font-weight: bold; 116 font-weight: bold;
117 text-align: center; 117 text-align: center;
118 margin: 1em; 118 margin: 1em;
119 clear: both;
120}
121div#content p a {
122 font-weight: bold;
119} 123}
120 124
121div.insert { 125div.insert {
122 text-align: center; 126 text-align: center;
123} 127}
124iframe#insert { 128iframe#insert {
125 border: 1px solid black; 129 border: 1px solid black;
126} 130}
@@ -170,8 +174,32 @@ ul.sourcebrowser li.file a {
170 text-decoration: none; 174 text-decoration: none;
171 font-family: monospace; 175 font-family: monospace;
172} 176}
173ul.sourcebrowser li.file a:hover { 177ul.sourcebrowser li.file a:hover {
174 background: gray; 178 background: gray;
175 border: 1px solid black; 179 border: 1px solid black;
176 color: white; 180 color: white;
177} 181}
182
183div.prevnext {
184 margin: 1ex;
185}
186div.prevnext a {
187 margin: 0.5ex 1em; padding: 0.2ex 0.5ex;
188 display: block; width: 30%;
189 border: solid 1px gray;
190 color: black;
191 text-decoration: none;
192}
193div.prevnext a.prevnext-prev {
194 float: left;
195 text-align: left;
196}
197div.prevnext a.prevnext-next {
198 float: right;
199 text-align: right;
200}
201div.prevnext a:hover {
202 background: gray;
203 border: black 1px solid;
204 color: white;
205}