summaryrefslogtreecommitdiff
path: root/data/tpl
diff options
context:
space:
mode:
authoryorhel <yorhel@1fe2e327-d9db-4752-bcf7-ef0cb4a1748b>2008-05-01 08:44:25 +0000
committeryorhel <yorhel@1fe2e327-d9db-4752-bcf7-ef0cb4a1748b>2008-05-01 08:44:25 +0000
commit59f6e2061ab2c19a626813e99b59d416f730180c (patch)
treedc080dd22ce4578cb9b9b893cf74ea9ccb53bba1 /data/tpl
parent2e533bd16346ec74216415c01a57c7276d608cf8 (diff)
Another batch of changes... see the ChangeLog!
git-svn-id: svn://vndb.org/vndb@10 1fe2e327-d9db-4752-bcf7-ef0cb4a1748b
Diffstat (limited to 'data/tpl')
-rw-r--r--data/tpl/defs.pl20
-rw-r--r--data/tpl/docs296
-rw-r--r--data/tpl/error53
-rw-r--r--data/tpl/main145
-rw-r--r--data/tpl/page140
-rw-r--r--data/tpl/vnpage_rel10
6 files changed, 169 insertions, 495 deletions
diff --git a/data/tpl/defs.pl b/data/tpl/defs.pl
index c482478a..e993fb58 100644
--- a/data/tpl/defs.pl
+++ b/data/tpl/defs.pl
@@ -180,13 +180,21 @@ sub ttabs { # [vrp], obj, sel
sprintf('<a href="/%%s/hide"%s>%s</a>', $t eq 'v' ? ' id="vhide"' : '', $$o{hidden} ? 'unhide' : 'hide')
) : (),
!$$o{locked} || ($p{Authedit} && $p{Authlock}) ?
- ($s eq 'edit' ? 'edit' : '<a href="/%s/edit" '.($t eq 'v' || $t eq 'r' ? 'class="dropdown" rel="nofollow editDD"':'').'>edit</a>') : (),
+ ($s eq 'edit' ? 'edit' : '<a href="'.($p{Authedit}?'/%s/edit':'/u/register?n=1').'" '.($t eq 'v' || $t eq 'r' ? 'class="dropdown" rel="nofollow editDD"':'').'>edit</a>') : (),
$p{Authhist} ?
($s eq 'hist' ? 'history' : '<a href="/%s/hist">history</a>') : (),
);
return '<p class="mod">&lt; '.join(' - ', map { sprintf $_, $t.$$o{id} } @act).' &gt;</p>'.(
- $t eq 'v' ? qq|
+ !$p{Authedit} ? qq|
+<div id="editDD" class="dropdown">
+ <ul>
+ <li><b>Not logged in</b></li>
+ <li><a href="/u/login">Login</a></li>
+ <li><a href="/u/register">Register</a></li>
+ </ul>
+</div>
+ | : $t eq 'v' ? qq|
<div id="editDD" class="dropdown">
<ul>
<li><a href="/v$$o{id}/edit" rel="nofollow">Edit all</a></li>
@@ -250,11 +258,9 @@ my %pagetitles = (
hist => sub {
return !$p{hist}{id} || !$p{hist}{type} ? 'Recent changes' :
$p{hist}{type} eq 'u' ? 'Recent changes by '.$p{hist}{title} : 'Edit history of '.$p{hist}{title}; },
- docs => sub {
- return (
- 'Categories', 'Adding/editing a visual novel', 'Adding/editing a release',
- 'Adding/editing a producer', 'General guidelines', 'Error parsing form',
- )[$p{docs}{p}-1]||'' }
+ docs => sub { $p{docs}{title} },
+ error => sub {
+ $p{error}{err} eq 'notfound' ? '404 Page Not Found' : 'Error Parsing Form' },
);
sub gettitle{$p{$_}&&($p{PageTitle}=ref($pagetitles{$_}) eq 'CODE' ? &{$pagetitles{$_}} : $pagetitles{$_}) for (keys%pagetitles);}
diff --git a/data/tpl/docs b/data/tpl/docs
index 1ca812c2..6aeefe81 100644
--- a/data/tpl/docs
+++ b/data/tpl/docs
@@ -1,298 +1,4 @@
-[[ if(0) { ]]
-<p class="mod">&lt; <a href="/d1">categories</a> - <a href="/d2">visual novels</a> - <a href="/d3">releases</a> - <a href="/d4">producers</a> - <a href="/d5">general guidelines</a> &gt;</p>
-[[ } ]]
<h2>[[: $p{PageTitle} ]]</h2>
<div id="dpage">
-
-[[ # C A T E G O R I E S
- if($d{p} == 1) { ]]
-
-<h3>Elements</h3>
-<p>
- ...own interpretation for now... (Should be documented at some time, too)
-</p>
-
-
-<h3>Gameplay</h3>
-<p>
- This category is used to describe the gameplay or game engine.
-</p>
-<dl>
- <dt>Visual Novel</dt><dd>
- All games where the text is overlaid on the background and there is no special
- dialog-box fall under this category. Can be abbreviated as VN or NVL.
- </dd><dt>Adventure</dt><dd>
- This is the opposite of the <i>Visual Novel</i> category: The text is presented
- in a special window, usually at the bottom of the screen. In some (rare) cases
- a game will switch between both styles, for these games both the <i>Visual Novel</i>
- and <i>Adventure</i> categories should be selected. Can be abbreviated as ADV or AVG.
- </dd><dt>Action</dt><dd>
- This category indicates that the game includes a gameplay that challenges the
- player's speed, dexterity and reaction time. Common examples are fighting games,
- puzzles that should be solved within a short time limit, and shooter games.
- </dd><dt>RPG</dt><dd>
- Abbreviation for Role Playing Game. An RPG is a game in which you assume the
- role of a character introduced to a vast world to be explored. Games typically
- place emphasis on gaining equipment and experience points through fighting enemies
- in order to advance through different levels.
- </dd><dt>Strategy</dt><dd>
- A strategy game is one that challenges the player to think critically in order
- to achieve victory.
- </dd><dt>Simulation</dt><dd>
- A simulation game attempts to recreate aspects of reality and puts the player in
- control.
- </dd>
-</dl>
-
-<h3>Plot</h3>
-<p>
- Indicates the plot type of a game. There are only two options: <i>Branching</i> and
- <i>Linear</i>.
-</p>
-<dl>
- <dt>Linear</d><dd>
- A game with a linear plot has a static story; it is not possible to get different paths
- or endings. Many games in this category do not prompt the player with choices and simply
- tell the story as it is. This is, however, not a rule: it is also possible for a game
- to provide choises, but they have no influence on the story itself. (e.g.
- <a href="/v3">Utawarerumono</a>)
- </dd><dt>Branching</dt><dd>
- A game with a branching plot has a story whose path is directly affected by choices
- made by the player during the game. These different paths are sometimes referred to
- as "arcs" when they pertain to the stories of different female characters within a game.
- </dd>
-</dl>
-
-<h3>Time</h3>
-<p>
- Indicates the time period in which the story has been set.
-</p>
-<dl>
- <dt>Future</dt><dd>
- The game is set in a time beyond that of our own. Games may incorperate elements of
- future technologies or events yet-to-come.
- </dd><dt>Present</dt><dd>
- The game is set in the current day.
- </dd><dt>Past</dt><dd>
- The game is set in a time before our own. Games may or may not adhere to historic fact.
- </dd>
-</dl>
-
-<h3>Place</h3>
-<p>
- Indicates the place in which the story is told.
-</p>
-<dl>
- <dt>Earth</dt><dd>
- The game takes place on our own planet.
- </dd><dt>Fantasy World</dt><dd>
- The game takes place on another world. The game's environment could be similar
- to that of our own with a few significant changes, but it could also be
- radically different.
- </dd><dt>Space</dt><dd>
- The game takes place in the vacuum of space between celestial bodies. For example,
- this category can be used to define games where the characters may inhabit
- spaceships that journey across the universe.
- </dd>
-</dl>
-
-<h3>Sexual content</h3>
-<p>
- Indicates the types of sexual content that the game contains.
-</p>
-<dl>
- <dt>Sexual content</dt><dd>
- This is a generic category to indicate the presence of any sexual content in the
- game. If there is any such content, this category should be selected.
- </dd><dt>Bestiality</dt><dd>
- Sexual activity between characters and animals.<br />
- <i>No catgirls, I guess?</i>
- </dd><dt>Incest</dt><dd>
- Sexual activity between members of the same family. Most of the time under the
- justification of participants not blood related (step-sister etc.).
- </dd><dt>Lolicon</dt><dd>
- The usage of female characters with childlike features in sexual situations.
- </dd><dt>Shotacon</dt><dd>
- The usage of male characters with childlike features in sexual situations.
- </dd><dt>Yaoi</dt><dd>
- Sexual content depicting activity between males.
- </dd><dt>Yuri</dt><dd>
- Sexual content depicting activity between females.
- </dd><dt>Rape</dt><dd>
- Situation in which a character is made to engage in sexual activities against
- their will.
- </dd>
-</dl>
-
-
-
-
-[[ } # V I S U A L N O V E L A D D / E D I T
- if($d{p} == 2) { ]]
-
-<p>
- Blahblah about what we define as VN? Or should that be in <a href="/d5">General guidelines</a>?
-</p>
-
-<h3>General info</h3>
-<dl>
- <dt>*Title</dt><dd>
- ..
- </dd><dt>Aliases</dt><dd>
- ..
- </dd><dt>*Description</dt><dd>
- ..
- </dd><dt>Length</dt><dd>
- ..
- </dd><dt>External links</dt><dd>
- ..
- </dd>
-</dl>
-
-<h3>Categories</h3>
-<p>
- See <a href="/d1">Categories</a>.
-</p>
-
-<h3>Image</h3>
-<p>
- <i>General image guidelines and when to use the NSFW warning</i>
-</p>
-
-<h3>Relations</h3>
-<p>
- <i>When to add relation, and document direct and reverse relations</i><br />
- <i>(Stolen from AniDB, needs some rewriting)</i>
-</p>
-<dl>
- <dt>Sequel</dt><dd>
- Continuation of the story. &lt;=&gt;<i>Prequel</i>.
- </dd><dt>Prequel</dt><dd>
- The story happens before the original story.&lt;=&gt;<i>Sequel</i>.
- </dd><dt>Same setting</dt><dd>
- Same universe/world/reality/timeline, completely different characters.
- </dd><dt>Alternative setting</dt><dd>
- Same characters, different universe/world/reality/timeline.
- </dd><dt>Alternative version</dt><dd>
- Same setting, same characters, story is told differently.
- </dd><dt>Same characters</dt><dd>
- Shares one or more characters, story is unrelated.
- </dd><dt>Side story</dt><dd>
- Takes place sometime during the parent storyline. &lt;=&gt;<i>Parent story</i>
- </dd><dt>Parent story</dt><dd>
- .. &lt;=&gt;<i>Side story</i>.
- </dd><dt>Summary</dt><dd>
- Summarizes full story, may contain additional stuff. &lt;=&gt;<i>Full story</i>.
- </dd><dt>Full story</dt><dd>
- Full version of the summarized story. &lt;=&gt;<i>Summary</i>.
- </dd><dt>Other</dt><dd>
- ..
- </dd>
-</dl>
-
-
-
-
-
-
-[[ } # R E L E A S E A D D / E D I T
- if($d{p} == 3) { ]]
-
-<p>
- <i>When to add a release</i>
-</p>
-
-<h3>General info</h3>
-<dl>
- <dt>*Type</dt><dd>
- ..
- </dd><dt>*Title (romaji)</dt><dd>
- ..
- </dd><dt>Original title</dt><dd>
- ..
- </dd><dt>*Language</dt><dd>
- ..
- </dd><dt>Official website</dt><dd>
- ..
- </dd><dt>Release date</dt><dd>
- ..
- </dd><dt>Age rating</dt><dd>
- ..
- </dd><dt>Notes</dt><dd>
- ..
- </dd>
-</dl>
-
-<h3>Platforms &amp; Media</h3>
-<dl>
- <dt>Platforms</dt><dd>
- ..
- </dd><dt>Media</dt><dd>
- ..
- </dd>
-</dl>
-
-<h3>Producers</h3>
-..
-
-<h3>Visual novel relations</h3>
-..
-
-
-
-
-
-
-[[ } # P R O D U C E R A D D / E D I T
- if($d{p} == 4) { ]]
-
-<p>
- <i>When to add a producer and what to do with producer relations...</i>
-</p>
-
-<h3>General info</h3>
-<dl>
- <dt>*Type</dt><dd>
- ..
- </dd><dt>*Name (romaji)</dt><dd>
- ..
- </dd><dt>Original name</dt><dd>
- ..
- </dd><dt>*Primary language</dt><dd>
- ..
- </dd><dt>Website</dt><dd>
- ..
- </dd><dt>Description</dt><dd>
- ..
- </dd>
-</dl>
-
-
-
-
-[[ } # G E N E R A L G U I D E L I N E S
- if($d{p} == 5) { ]]
-
-
-Misc documentation:<br />
-- Romanisation and capitalization (http://wiki.anidb.net/w/Romanisation)<br />
-- What to do with fandisks<br />
-- Edit summary<br />
-- Quoting sources in descriptions<br />
-- Piracy<br />
-- Spoilers<br />
-
-
-
-
-[[ } # N O S P A M M E S S A G E
- if($d{p} == 6) { ]]
-
-<span class="warning">
- <b>Error:</b> The form could not be sent, please make sure you have Javascript
- enabled in your browser!
-</span>
-
-
-[[ } ]]
+[[= $d{content} ]]
</div>
diff --git a/data/tpl/error b/data/tpl/error
index 76bd9462..995293d1 100644
--- a/data/tpl/error
+++ b/data/tpl/error
@@ -1,45 +1,10 @@
-<head>
- <title>
- [[ if($X->{error}->{code} == 1) { ]]VNDB offline
- [[ } else { ]] ERROR: [[= $X->{error}->{code} ]][[ } ]]
- </title>
-
- <meta name="Robots" content="index, follow" />
- <link href="/favicon.ico" type="image/x-icon" rel="shortcut icon" />
+<h2>[[: $p{PageTitle} ]]</h2>
+[[ if($d{err} eq 'notfound') { ]]
+ The page you were looking for could not be found!
- <style type="text/css">
- body { background-color: #e0e0e0; padding: 0px; text-align: center; font-family: "Arial", Sans-serif; font-size: 11px; line-height: 16px; font-weight: normal; color: #242424; }
- #wrapper { margin: 0px auto; margin-bottom: 20px; background-color: #fff; text-align: center; width: 672px; border: 1px solid #b8b8b8; }
- #pre { background-color: #fff; text-align: left; padding: 0px 10px 5px 10px; margin: 5px 5px 5px 5px; border: 1px solid #e9e9e9; }
- p { font-size: 11px; color: #242424; text-align: justify; padding-left: 17px; padding-right: 17px; }
- h1 { font-size: 16px; font-weight: bold; color: #242424; padding-left: 17px; }
- a { color: #33659E; text-decoration: none; }
- a:hover { text-decoration: underline; }
- img { border: 0; margin: 0; padding: 0; }
- [[ if($X->{error}->{code} == 500) { ]]
- #wrapper { width: 530px; }
- [[ } ]]
- </style>
-</head>
-<body>
- <div id="wrapper">
- <div id="pre">
- [[ if($X->{error}->{code} > 300 && $X->{error}->{code} < 310) { ]]
- <h1>Moved</h1>
- <p>
- Check <a href="[[% $X->{error}->{url} ]]">[[: $X->{error}->{url} ]]</a> for the new location.
- </p>
- [[ } elsif($X->{error}->{code} == 401) { ]]
- <h1>Login required</h1>
- <p>
- <a href="/">Please login</a>
- </p>
- [[ } elsif($X->{error}->{code} == 1) { ]]
- <h1>VNDB offline</h1>
- <p>
- [[: $X->{error}->{msg} ]]
- </p>
- [[ } ]]
- </div>
- </div>
-</body>
+[[ } elsif($d{err} eq 'formerr') { ]]
+<span class="warning">
+ <b>Error:</b> The form could not be sent, please make sure you have Javascript
+ enabled in your browser!
+</span>
+[[ } ]]
diff --git a/data/tpl/main b/data/tpl/main
index d52a576a..cbac2729 100644
--- a/data/tpl/main
+++ b/data/tpl/main
@@ -1,14 +1,149 @@
[[+ defs.pl ]]
+[[ %p = %{$X->{page}}; gettitle(); ]]
<!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" xml:lang="en" lang="en">
-
--[[ if($X->{error}) { ]]
- [[+ error ]]
-[[ } if($X->{page}) { %p = %{$X->{page}}; gettitle(); ]]
- [[+ page ]]
+
+<head>
+ <title>[[: $p{PageTitle} ]]- :: VNDB</title>
+ <link href="[[: $p{st} ]]/files/style.css?[[= $VNDB::VERSION ]]" rel="stylesheet" type="text/css" media="screen" />
+ <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" />
+[[ if($p{redit} || $p{vnedit}) { ]]-
+ <script src="[[: $p{st} ]]/files/dyna.js?[[= $VNDB::VERSION ]]" type="text/javascript"></script>
+[[ } ]]-
+ <script src="[[: $p{st} ]]/files/def.js?[[= $VNDB::VERSION ]]" type="text/javascript"></script>
+[[ if($p{devshit}) { ]]-
+ <meta name="robots" content="noindex, nofollow" />
+[[ } elsif($p{userlist} || $p{userpage} || $p{myvotes} || $p{vnlist} || $p{hist} || ($p{vnpage} && $p{vnpage}{page} eq 'stats')
+ || grep { $p{$_} && $p{$_}{change} } qw|vnpage ppage rpage|) { ]]-
+ <meta name="robots" content="noindex, follow" />
+[[ }]]-
+
+[[if($p{hist}){ ]]
+ <link rel="alternate" type="application/rss+xml" title="Recent changes" href="
+ [[= (!$p{hist}{type}?'/hist':'/'.$p{hist}{type}.$p{hist}{id}.'/hist').'/rss'.(!$p{hist}{type}?'?t='.$p{hist}{selt}.';e='.$p{hist}{sele}:$p{hist}{type} eq 'v' && $p{hist}{seli} ? '?i=1':'') ]]" />
+[[ } ]]-
+</head>
+
+<body>
+<div id="header">
+ <form id="search" method="get" action="/v/search">
+ <fieldset>
+ <legend>Search</legend>
+ <input id="searchfield" type="text" name="q" value="[[: $p{searchquery} || 'search' ]]"[[= !$p{searchquery} ? ' style="color: #999"': '' ]]- />
+ <input id="searchsubmit" type="submit" value="Search" />
+ </fieldset>
+ </form>
+ <h1><a href="/">vndb.org</a> / #vndb @ irc.synirc.net <a href="http://vndb.org/">
+ [[ if($p{devshit}) { ]]<b style="color: red">The VNDB.org Testing Grounds</b>[[ } else { ]]<b>The Visual Novel Database</b>[[ } ]]</a></h1>
+</div>
+
+
+<div id="page">
+
+<div id="content">
+[[ # = noindex-tag (see above) ]]
+[[ if($p{home}) { %d = %{$p{home}}; ]] [[+ home ]][[ } ]]
+[[ if($p{userlogin}) { %d = %{$p{userlogin}}; ]] [[+ userlogin ]][[ } ]]
+[[ if($p{userreg}) { %d = %{$p{userreg}}; ]] [[+ userreg ]][[ } ]]
+[[ if($p{userpass}) { %d = %{$p{userpass}}; ]] [[+ userpass ]][[ } ]]
+[[ if($p{useredit}) { %d = %{$p{useredit}}; ]] [[+ useredit ]][[ } ]]
+[[ if($p{userlist}) { %d = %{$p{userlist}}; ]] [[+ userlist ]][[ }# ]]
+[[ if($p{userpage}) { %d = %{$p{userpage}}; ]] [[+ userpage ]][[ }# ]]
+[[ if($p{vnpage}) { %d = %{$p{vnpage}}; ]] [[+ vnpage ]][[ } ]]
+[[ if($p{vnedit}) { %d = %{$p{vnedit}}; ]] [[+ vnedit ]][[ } ]]
+[[ if($p{redit}) { %d = %{$p{redit}}; ]] [[+ redit ]][[ } ]]
+[[ if($p{vnbrowse}) { %d = %{$p{vnbrowse}}; ]] [[+ vnbrowse ]][[ } ]]
+[[ if($p{pbrowse}) { %d = %{$p{pbrowse}}; ]] [[+ pbrowse ]][[ } ]]
+[[ if($p{pedit}) { %d = %{$p{pedit}}; ]] [[+ pedit ]][[ } ]]
+[[ if($p{ppage}) { %d = %{$p{ppage}}; ]] [[+ ppage ]][[ } ]]
+[[ if($p{myvotes}) { %d = %{$p{myvotes}}; ]] [[+ myvotes ]][[ }# ]]
+[[ if($p{vnlist}) { %d = %{$p{vnlist}}; ]] [[+ vnlist ]][[ }# ]]
+[[ if($p{hist}) { %d = %{$p{hist}}; ]] [[+ hist ]][[ }# ]]
+[[ if($p{rpage}) { %d = %{$p{rpage}}; ]] [[+ rpage ]][[ } ]]
+[[ if($p{docs}) { %d = %{$p{docs}}; ]] [[+ docs ]][[ } ]]
+[[ if($p{error}) { %d = %{$p{error}}; ]] [[+ error ]][[ } ]]
+</div>
+
+
+<div id="side"><div><div>
+
+ <h2>Menu</h2>
+ <ul>
+ <li><a href="/">Home</a></li>
+ <li><a href="/v">Visual Novels</a></li>
+ <li><a href="/p">Producers</a></li>
+ <li><a href="/v/cat">Categories</a></li>
+ <li><a href="/u/list">Users</a></li>
+ <li><a href="/hist">Recent changes</a></li>
+ <li><a href="/d6">FAQ</a></li>
+ <li><a href="http://forum.vndb.org/">Forum</a></li>
+ </ul>
+
+-[[ if(!$p{AuthLoggedin}) { ]]-
+ <h2>Login</h2>
+ <form method="post" action="/nospam?/u/login" id="loginform">
+ <fieldset>
+ <legend>Login</legend>
+ <input type="text" id="usrname" name="username" />
+ <input type="password" id="usrpass" name="userpass" />
+ <input type="submit" value="Login" />
+ </fieldset>
+ </form>
+ <p>
+ <a href="/u/register">register</a> or <a href="/u/newpass">forgot password?</a>
+ </p>
+[[ } else { ]]-
+ <h2>User menu</h2>
+ <ul>
+ <li>[[: $p{AuthUsername} ]]- ([[: $p{AuthRankname} ]])</li>
+ <li><a href="/u[[= $p{AuthId} ]]/edit">My profile</a></li>
+ <li><a href="/u[[= $p{AuthId} ]]/votes">My votes</a></li>
+ <li><a href="/u[[= $p{AuthId} ]]/list">My visual novel list</a></li>
+ <li><a href="/u[[= $p{AuthId} ]]/hist">My recent changes</a></li>
+ [[ if($p{Authedit}) { ]]-
+ <li>&nbsp;</li>
+ <li><a href="/v/new">Add visual novel</a></li>
+ <li><a href="/p/add">Add producer</a></li>
+ [[ } ]]
+ <li>&nbsp;</li>
+ <li><a href="/u/logout">Logout</a></li>
+ </ul>
+[[ } ]]-
+
+-[[ #</div></div><div><div> ]]
+ <h2>Statistics</h2>
+ <ul>
+ <li><b>[[= $p{Statvn}||0 ]]</b> visual novels</li>
+ <li><b>[[= $p{Statproducers}||0 ]]</b> producers</li>
+ <li><b>[[= $p{Statreleases}||0 ]]</b> releases</li>
+ <li><b>[[= $p{Statvotes}||0 ]]</b> votes</li>
+ <li><b>[[= $p{Statusers}||0 ]]</b> users</li>
+ </ul>
+[[ if(0) { ]] <h2>Most popular</h2>
+ <ul>[[ for (@{$p{popular}}) { ]]-
+ <li><a href="/v[[: $_->{id} ]]" title="[[: $_->{title} ]]">[[: length($_->{title})>30 ? (substr($_->{title}, 0, 27).'...') : $_->{title} ]]</a></li>[[ } ]]-
+ <li class="more"><a href="/v/all?s=votes&amp;o=d">More...</a></li>
+ </ul>[[ } ]]-
+</div></div></div>
+
+</div>
+
+<div id="footer">
+ <p>
+ vndb v[[: $VNDB::VERSION ]]- |
+ <a href="mailto:contact@vndb.org">contact@vndb.org</a> |
+ designed by <a href="http://www.freecsstemplates.org/">free css templates</a>.
+ </p>
+</div>
+
+-[[ if(0 && $p{devshit}) { ]]-
+ <pre id="debug">SQL Queries used:<br />
+[[= $p{devshit} ]]
+</pre>
[[ } ]]-
+</body>
</html>
diff --git a/data/tpl/page b/data/tpl/page
deleted file mode 100644
index e6ce9e99..00000000
--- a/data/tpl/page
+++ /dev/null
@@ -1,140 +0,0 @@
-<head>
- <title>[[: $p{PageTitle} ]]- :: VNDB</title>
- <link href="[[: $p{st} ]]/files/style.css?[[= $VNDB::VERSION ]]" rel="stylesheet" type="text/css" media="screen" />
- <link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" />
-[[ if($p{redit} || $p{vnedit}) { ]]-
- <script src="[[: $p{st} ]]/files/dyna.js?[[= $VNDB::VERSION ]]" type="text/javascript"></script>
-[[ } ]]-
- <script src="[[: $p{st} ]]/files/def.js?[[= $VNDB::VERSION ]]" type="text/javascript"></script>
-[[ if($p{devshit}) { ]]-
- <meta name="robots" content="noindex, nofollow" />
-[[ } elsif($p{userlist} || $p{userpage} || $p{myvotes} || $p{vnlist} || $p{hist} || ($p{vnpage} && $p{vnpage}{page} eq 'stats')
- || grep { $p{$_} && $p{$_}{change} } qw|vnpage ppage rpage|) { ]]-
- <meta name="robots" content="noindex, follow" />
-[[ }]]-
-
-[[if($p{hist}){ ]]
- <link rel="alternate" type="application/rss+xml" title="Recent changes" href="
- [[= (!$p{hist}{type}?'/hist':'/'.$p{hist}{type}.$p{hist}{id}.'/hist').'/rss'.(!$p{hist}{type}?'?t='.$p{hist}{selt}.';e='.$p{hist}{sele}:$p{hist}{type} eq 'v' && $p{hist}{seli} ? '?i=1':'') ]]" />
-[[ } ]]-
-</head>
-
-<body>
-<div id="header">
- <form id="search" method="get" action="/v/search">
- <fieldset>
- <legend>Search</legend>
- <input id="searchfield" type="text" name="q" value="[[: $p{searchquery} || 'search' ]]"[[= !$p{searchquery} ? ' style="color: #999"': '' ]]- />
- <input id="searchsubmit" type="submit" value="Search" />
- </fieldset>
- </form>
- <h1><a href="/">vndb.org</a> / #vndb @ irc.synirc.net <a href="http://vndb.org/">
- [[ if($p{devshit}) { ]]<b style="color: red">The VNDB.org Testing Grounds</b>[[ } else { ]]<b>The Visual Novel Database</b>[[ } ]]</a></h1>
-</div>
-
-
-<div id="page">
-
-<div id="content">
-[[ # = noindex-tag (see above) ]]
-[[ if($p{home}) { %d = %{$p{home}}; ]] [[+ home ]][[ } ]]
-[[ if($p{faq}) { %d = %{$p{faq}}; ]] [[+ faq ]][[ } ]]
-[[ if($p{userlogin}) { %d = %{$p{userlogin}}; ]] [[+ userlogin ]][[ } ]]
-[[ if($p{userreg}) { %d = %{$p{userreg}}; ]] [[+ userreg ]][[ } ]]
-[[ if($p{userpass}) { %d = %{$p{userpass}}; ]] [[+ userpass ]][[ } ]]
-[[ if($p{useredit}) { %d = %{$p{useredit}}; ]] [[+ useredit ]][[ } ]]
-[[ if($p{userlist}) { %d = %{$p{userlist}}; ]] [[+ userlist ]][[ }# ]]
-[[ if($p{userpage}) { %d = %{$p{userpage}}; ]] [[+ userpage ]][[ }# ]]
-[[ if($p{vnpage}) { %d = %{$p{vnpage}}; ]] [[+ vnpage ]][[ } ]]
-[[ if($p{vnedit}) { %d = %{$p{vnedit}}; ]] [[+ vnedit ]][[ } ]]
-[[ if($p{redit}) { %d = %{$p{redit}}; ]] [[+ redit ]][[ } ]]
-[[ if($p{vnbrowse}) { %d = %{$p{vnbrowse}}; ]] [[+ vnbrowse ]][[ } ]]
-[[ if($p{pbrowse}) { %d = %{$p{pbrowse}}; ]] [[+ pbrowse ]][[ } ]]
-[[ if($p{pedit}) { %d = %{$p{pedit}}; ]] [[+ pedit ]][[ } ]]
-[[ if($p{ppage}) { %d = %{$p{ppage}}; ]] [[+ ppage ]][[ } ]]
-[[ if($p{myvotes}) { %d = %{$p{myvotes}}; ]] [[+ myvotes ]][[ }# ]]
-[[ if($p{vnlist}) { %d = %{$p{vnlist}}; ]] [[+ vnlist ]][[ }# ]]
-[[ if($p{hist}) { %d = %{$p{hist}}; ]] [[+ hist ]][[ }# ]]
-[[ if($p{rpage}) { %d = %{$p{rpage}}; ]] [[+ rpage ]][[ } ]]
-[[ if($p{docs}) { %d = %{$p{docs}}; ]] [[+ docs ]][[ } ]]
-</div>
-
-
-<div id="side"><div><div>
-
- <h2>Menu</h2>
- <ul>
- <li><a href="/">Home</a></li>
- <li><a href="/v">Visual Novels</a></li>
- <li><a href="/p">Producers</a></li>
- <li><a href="/v/cat">Categories</a></li>
- <li><a href="/u/list">Users</a></li>
- <li><a href="/hist">Recent changes</a></li>
- <li><a href="/faq">FAQ</a></li>
- <li><a href="http://forum.vndb.org/">Forum</a></li>
- </ul>
-
--[[ if(!$p{AuthLoggedin}) { ]]-
- <h2>Login</h2>
- <form method="post" action="/nospam?/u/login" id="loginform">
- <fieldset>
- <legend>Login</legend>
- <input type="text" id="usrname" name="username" />
- <input type="password" id="usrpass" name="userpass" />
- <input type="submit" value="Login" />
- </fieldset>
- </form>
- <p>
- <a href="/u/register">register</a> or <a href="/u/newpass">forgot password?</a>
- </p>
-[[ } else { ]]-
- <h2>User menu</h2>
- <ul>
- <li>[[: $p{AuthUsername} ]]- ([[: $p{AuthRankname} ]])</li>
- <li><a href="/u[[= $p{AuthId} ]]/edit">My profile</a></li>
- <li><a href="/u[[= $p{AuthId} ]]/votes">My votes</a></li>
- <li><a href="/u[[= $p{AuthId} ]]/list">My visual novel list</a></li>
- <li><a href="/u[[= $p{AuthId} ]]/hist">My recent changes</a></li>
- [[ if($p{Authedit}) { ]]-
- <li>&nbsp;</li>
- <li><a href="/v/new">Add visual novel</a></li>
- <li><a href="/p/add">Add producer</a></li>
- [[ } ]]
- <li>&nbsp;</li>
- <li><a href="/u/logout">Logout</a></li>
- </ul>
-[[ } ]]-
-
--[[ #</div></div><div><div> ]]
- <h2>Statistics</h2>
- <ul>
- <li><b>[[= $p{Statvn}||0 ]]</b> visual novels</li>
- <li><b>[[= $p{Statproducers}||0 ]]</b> producers</li>
- <li><b>[[= $p{Statreleases}||0 ]]</b> releases</li>
- <li><b>[[= $p{Statvotes}||0 ]]</b> votes</li>
- <li><b>[[= $p{Statusers}||0 ]]</b> users</li>
- </ul>
-[[ if(0) { ]] <h2>Most popular</h2>
- <ul>[[ for (@{$p{popular}}) { ]]-
- <li><a href="/v[[: $_->{id} ]]" title="[[: $_->{title} ]]">[[: length($_->{title})>30 ? (substr($_->{title}, 0, 27).'...') : $_->{title} ]]</a></li>[[ } ]]-
- <li class="more"><a href="/v/all?s=votes&amp;o=d">More...</a></li>
- </ul>[[ } ]]-
-</div></div></div>
-
-</div>
-
-<div id="footer">
- <p>
- vndb v[[: $VNDB::VERSION ]]- |
- <a href="mailto:contact@vndb.org">contact@vndb.org</a> |
- designed by <a href="http://www.freecsstemplates.org/">free css templates</a>.
- </p>
-</div>
-
--[[ if(0 && $p{devshit}) { ]]-
- <pre id="debug">SQL Queries used:<br />
-[[= $p{devshit} ]]
-</pre>
-[[ } ]]-
-
-</body>
diff --git a/data/tpl/vnpage_rel b/data/tpl/vnpage_rel
index f0edc35d..ea5c5235 100644
--- a/data/tpl/vnpage_rel
+++ b/data/tpl/vnpage_rel
@@ -29,10 +29,12 @@
<tr>
<td class="tc1">[[= datestr($_->{released}) ]]</td>
<td class="tc2">[[= $_->{minage}<0 ? '' : $VNDB::VRAGES->{$_->{minage}} ]]</td>
- <td class="tc3">[[= join('', map { $_ ne 'oth' ? '<acronym class="plat '.$_.'" title="'._hchar($VNDB::PLAT->{$_}).'">&nbsp;</acronym>' : () } sort @{$_->{platforms}}) ]]</td>
- <td class="tc4"><acronym title="[[= $VNDB::RTYP->[$_->{type}] ]]- release">[[= lc substr($VNDB::RTYP->[$_->{type}],0,1) ]]</acronym></td>
- <td class="tc5"><a href="/r[[= $_->{id} ]]" title="[[: $_->{original} || $_->{title} ]]">[[: shorten $_->{title},60 ]]</a></td>
- <td class="tc7">[[ if($_->{website}) { ]]<a href="[[: $_->{website} ]]" class="plat ext" title="WWW">&nbsp;</a>[[ } ]]</td>
+ <td class="tc3">
+ [[= join('', map { $_ ne 'oth' ? '<acronym class="plat '.$_.'" title="'._hchar($VNDB::PLAT->{$_}).'">&nbsp;</acronym>' : () } sort @{$_->{platforms}}) ]]
+ <acronym title="[[= $VNDB::RTYP->[$_->{type}] ]]- release" class="plat -[[= lc substr($VNDB::RTYP->[$_->{type}],0,3) ]]">&nbsp;</acronym>
+ </td>
+ <td class="tc4"><a href="/r[[= $_->{id} ]]" title="[[: $_->{original} || $_->{title} ]]">[[: shorten $_->{title},60 ]]</a></td>
+ <td class="tc5">[[ if($_->{website}) { ]]<a href="[[: $_->{website} ]]" class="plat ext" title="WWW">&nbsp;</a>[[ } ]]</td>
</tr>
[[ } ]]-
[[ } ]]-