Source

alecwh / templates / site.html

Full commit
$def with (site_vars)
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
	<head>
		<title>alecwh &mdash; $site_vars['page_name'] (~$site_vars['session'].username)</title>
		<link rel="stylesheet" type="text/css" href="http://fonts.googleapis.com/css?family=Droid%20Sans:regular,bold" media="screen" />
		<link rel="stylesheet" type="text/css" href="$site_vars['base_url']static/css/_main.css" />
		<link rel="stylesheet" type="text/css" href="$site_vars['base_url']static/css/print.css" media="print" />
		<link rel="stylesheet" type="text/css" href="$site_vars['base_url']static/css/handheld.css" media="handheld" />
		<link rel="stylesheet" type="text/css" href="$site_vars['base_url']static/css/article_display.css" />
		<link rel="stylesheet" type="text/css" href="$site_vars['base_url']static/css/static_page.css" />
		<script type="text/javascript" src="$site_vars['base_url']static/js/jquery-1.3.2.min.js"></script>
		<script type="text/javascript" src="$site_vars['base_url']static/js/tag.js"></script>
		<script type="text/javascript" src="$site_vars['base_url']static/js/_site.js"></script>
		<link rel="alternate" type="application/rss+xml" title="Latest articles feed" href="/rss" /> 
	</head>
	<body class="$site_vars['page_type']">
		<!-- header start -->
		<div id="header">
			<div id="nav_wrapper">
			<ul>
				<li><a class="first" href="$site_vars['base_url']">Home</a></li>
				$if site_vars['session'].auth == 0:
					<li><a href="$site_vars['base_url']+login/">Log in</a></li>
				$else:
					<li><a class="logout" href="$site_vars['base_url']+logout/">Log out (~$site_vars['session'].username)</a></li>
				
			</ul>
			</div>
			<div class="page_actions"><a href="$site_vars['base_url']+feed/rss/" class="rss"><img src="$site_vars['base_url']static/images/rss.png" style="border:0"></a></div>
		</div>
		
		<div id="main_container">
			<!-- navigation bar start -->
			<div id="staticbar">
				<div id="navbar">
					<h2><a href="$site_vars['base_url']" longdesc="Point-blank blog application">Pb</a><span> ver 0.1</span></h2>
					<strong>Pages</strong>
					<ul>
						<li><a href="$site_vars['base_url']">Home</a></li>
						<li><a href="$site_vars['base_url']about.html">About me</a></li>
						<li><a href="$site_vars['base_url']contact.html">Contact</a></li>
						<li><a href="$site_vars['base_url']projects.html">Projects</a></li>
					</ul>
				
					<strong>My projects</strong>
					<ul>
						<li><a href="http://phpns.alecwh.com/">Phpns</a></li>
						<li><a href="$site_vars['base_url']pointblank.html">Point-blank</a></li>
						<li><a href="http://pyfig.alecwh.com/">Pyfig</a></li>
						<li><a href="$site_vars['base_url']projects">More here...</a></li>
					</ul>
				</div>
				<!--<div class="pullbox" id="page_tools">
					<a class="rss" href="$site_vars['base_url']+feed/rss/">RSS</a>
				</div>
				-->
				<!--
				<div class="pullbox archives">
					<h3>Archives</h3>
					<ul id="archives">
						<li><a href="#">October 2009</a></li>
						<li><a href="#">September 2009</a></li>
						<li><a href="#">August 2009</a></li>
						<li><a href="#">July 2009</a></li>
						<li><a href="#">June 2009</a></li>
					</ul>
				</div>
				-->
				<div class="pullbox">
				$if site_vars['session'].auth == 0:
					<h3>Log in <a href="#" class="toggle login">&#8664;</a></h3>
					<form action="$site_vars['base_url']+login/" method="post" class="login" id="side_login">
						<label><input type="text" class="text small" name="username" value="" /></label>
						<label><input type="password" class="text small" name="password" value="" /></label>
						<label><input type="submit" value="Login" /></label>
					</form>
					
				$else: 
					<h3>Hello $site_vars['session'].username!</h3>
					<p>You now are logged in.</p>
					<ul>
						<li><a class="admin_link" href="$site_vars['base_url']+logout/">Logout</a>
					</ul>
				
				</div>
				
				<div class="pullbox">
					<h3>Chatter <a href="#" class="toggle chatter">&#8664;</a></h3>
					<ul id="recent_comments">
						$site_vars['recent_comments_html']
					</ul>
				</div>
				
				<!--<div id="picture"><img src="http://www.gravatar.com/avatar/21f5359ed269a6ca2572fb10cd8b4615?s=120" alt="me"></div>-->
			</div>
		
			<!-- content start -->
			<div id="content">
				$if site_vars['page_type'] == "wiki":
					<div id="date_modified">Last modified: $site_vars['date_modified']</div>
					
				$site_vars['page_html']
			</div>
		</div>
		<div id="footer">Powered by <a href="http://alecwh.com/pointblank">Point-blank</a> &mdash; Code available <a href="http://bitbucket.org/alecwh/pointblank/">here</a></div>
	<!--<script type="text/javascript" src="http://localhost/alecwh/static/js/wmd/wmd/wmd.js"></script>-->
	</body>
</html>