-[#include <glib.h>]
+<% #include <glib.h> %>
-[void header() {]
-Content-Type: text/html; charset=UTF-8
-[}]
-
-
-[void frame_index(){]
+<% void frame_index(){ %>
<html>
<frameset rows="20, *">
- <frame name="head" src="?head">
- <frameset cols="240,*">
- <frame name="nav" src="?nav">
- <frame name="content" src="?content">
+ <frame name="head" src="head">
+ <frameset cols="248,*">
+ <frame name="nav" src="nav">
+ <frame name="content" src="content">
</frameset>
</frameset>
</html>
-[}]
+<% } %>
-[void frame_head(){]
+<% void frame_head(){ %>
<html>
<head>
<style>
</head>
<body>
<center>
- <a href="?noframe" target="parent">No Frames</a>
+ <a href="noframe" target="parent">No Frames</a>
</center>
</body>
</html>
-[}]
+<% } %>
-[void frame_nav(int square, GList *thumbs) {]
+<% void frame_nav(int square, GList *images) { %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
text-align:center;
text-decoration:none;
width:214px;
- [if (square)]
+ <% if (square) %>
height:214px;
}
.box {
</style>
</head>
<body>
- [for (GList *cur =thumbs; cur; cur = cur->next) {]
+ <% for (GList *cur = images; cur; cur = cur->next) { %>
+ <% gchar *img = (gchar *)cur->data; %>
<div class="align">
- <a class="box" target="content"
- [g_print("href=\"images/%s\"", (gchar*)cur->data);]
- ><img
- [g_print("src=\"thumbs/%s\"", (gchar*)cur->data);]
- ></a>
+ <a class="box" target="content" href="show_small?<%% "%s", img %>">
+ <img src="thumb/<%% "%s", img %>"></a>
</div>
- [}]
+ <% } %>
</body>
</html>
-[}]
-
+<% } %>
-[void frame_content(){]
-<html>
-</html>
-[}]
+<% void frame_show(char *this, char *link, char *image){ %>
+<html>
+ <body style="text-align:center;">
+ <a href="<%% "%s?%s", link, image %>">
+ <img src="<%% "%s/%s", this, image %>">
+ </a>
+ </body>
+</html>
+<% } %>