<?php

$template_matrix = array(
							array('index',				'webpage'),
							array('comments',			'webpage'),
							array('comment_preview',	'webpage'),
							array('trackbacks',			'webpage'),
							array('referrers',			'webpage'),
							array('smileys',			'webpage'),
							array('site_css',			'css')
						);

if ( ! isset($type))
	$type = 'core';


//-------------------------------------
//	Stylesheet template
//-------------------------------------

function site_css()
{
	global $type;

ob_start();
?>
/* layout */

body {
margin:0 auto;
padding:0;
min-width: 760px;
text-align: center;
font-family:arial, verdana, sans-serif;
background-color:#EFF3F4 ;
}

#wrapper {
margin: 0 auto;
width: 760px;
text-align: left;
background: url({site_url}themes/site_themes/trendy_blue/trendy_bg.jpg) repeat-y;
}

#blog-header {
padding:0px;
margin:0 34px;
background: url({site_url}themes/site_themes/trendy_blue/trendy_header_bg.jpg) repeat-x;
height:93px;
}

#blog-header-text {
padding:32px 0 0 13px;
float:left;
}

#content-wrapper {
width: 690px;
padding-left:00px;
padding-right:00px;
margin-left:34px;
}

#content {
float:left;
width:410px;
padding:20px;
padding-top:10px;
padding-bottom:50px;
background: url({site_url}themes/site_themes/trendy_blue/trendy_shadow.gif) repeat-x;
}

#sidebar {
float:right;
width:230px;
margin-left:10px;
}

#sidebar-content {
padding:5px;
}

#sidebar-top {
width:239px;
float:right;
height:20px;
margin-top:72px;
border-left:1px solid #94B1B7;
border-top:1px solid #94B1B7;
background: url({site_url}themes/site_themes/trendy_blue/trendy_top_bg.jpg) repeat-x bottom right;

}

#blog-footer {
padding:5px 5px 8px 20px;
background: url({site_url}themes/site_themes/trendy_blue/trendy_header_bg.jpg) repeat-x;
border-top:1px solid #666;
border-bottom:1px solid #ccc;
text-size:10px;
margin:0 34px;
}



/* text */

body {
font:12px arial, sans-serif;
}

a:link, a:active, a:visited {
font-weight:bold;
color:#333;
}

a:hover {
font-weight:bold;
text-decoration:none;
color:#000;
}

#blog-header-text h1 {
margin:0;
padding:0px 0 0px 50px;
color:#fff;
font: bold 44px arial, MS Trebuchet, sans-serif;
letter-spacing:-0.07em;
background: url({site_url}themes/site_themes/trendy_blue/trendy_arrow.gif) 5px 7px no-repeat;
}

#blog-header-text h1 a, #blog-header-text h1 a:link, #blog-header-text h1 a:visited, #blog-header-text h1 a:hover {
color:#fff;
font: bold 44px arial, MS Trebuchet, sans-serif;
letter-spacing:-0.07em;
text-decoration:none;
}

#sidebar-top #nav {
font:bold 11px arial, verdana, sans-serif;
padding:3px 2px 0 7px;
color:#94B1B7;
}

#sidebar-top a {}

#sidebar {color:#779BA4;}

#sidebar-top #nav a, #sidebar-top #nav a:link, #sidebar-top #nav a:visited, #sidebar-top #nav a:hover {
color:#333;
}

#sidebar ul {
padding:0;
margin:0;
list-style-type:none;
}

#sidebar h3.sidebar-header, #sidebar li.sidebar-header {
font:bold 12px arial, verdana, sans-serif;
color:#779BA4;
margin:0;
background: url({site_url}themes/site_themes/trendy_blue/trendy_grey_sq.gif) 0px 2px no-repeat;
padding-left:15px;
margin-bottom:5px;
}

#sidebar-content a, #sidebar-content a:link, #sidebar-content a:visited, #sidebar-content a:hover {
font-weight:normal;
color:#779BA4;
}

#sidebar-content ul {margin-bottom:15px;}
#sidebar-content ul li {padding-left:14px;margin-bottom:2px;}
#sidebar-content h3.sidebar-header {margin-top:15px;}
#sidebar-content h3.first {margin-top:5px;}
#sidebar-content p {margin:0;}

/* search */
#sidebar-content form {margin:0;padding:0;margin-bottom:15px;}
#sidebar-content input.input {border:1px solid #ccc;padding:3px;font-size:11px;color:#808080;}
#sidebar-content input.button {border:1px solid #ccc;background-color:#eee;padding:1px;padding-bottom:2px;font-size:11px;color:#808080;}

/* post */

h2.date-header {
font:bold 12px arial, verdana, sans-serif;
color:#779BA4;
margin:0;
margin-top:20px;
padding-bottom:8px;
padding-left:17px;
background: url({site_url}themes/site_themes/trendy_blue/trendy_grey_sq.gif) 0px 2px no-repeat;
}

.post {padding-bottom:15px;}

h3.post-header {
font:bold 32px arial, verdana, sans-serif;
letter-spacing:-0.07em;
color:#000;
margin:0;
margin-bottom:4px;
margin-top:5px;
}

.post-summary, post-summary p, .post-body, .post-body p { /* post-summary = index page ; post-body = comments page */
font:12px/18px arial, verdana, sans-serif;
color:#333;
}

.post-summary p, .post-body p {
margin-top:0;
margin-bottom:10px;
}


.post-details {margin-top:-5px;margin-bottom:5px;}

.post-details, .post-details a, .post-details a:visited, .post-details a:hover {
font:12px/18px arial, verdana, sans-serif;
color:#bbb;
padding-top:3px;
}


/* comments */

#comments-wrapper {
border-top: 1px solid #ccc;
padding-top:10px;
margin-top:20px;
}

#comments-wrapper h4, #comments-wrapper h4 a, #comments-wrapper h4 a:visited, #comments-wrapper h4 a:hover {
font: bold 14px  arial, verdana, sans-serif;
letter-spacing:-0.05em;
color:#779BA4;
}

.comment {
color:#666;
padding:10px;
}

.comment p {margin:10px 0;}

.one {background-color:#EFF3F4;}
.two {} /* alternate colour/styling if nec. */

.comment-details {
color:#999;
}

#post-comment {
color:#666;
border-top: 1px solid #ccc;
padding-top:10px;
margin-top:10px;
}

#post-comment h4 {
}


/* footer */

#blog-footer {
text-align:center;
color:#fff;
}

/* misc */

.clear {
clear: both;
}

img {
border:0;
padding:5px;
background-color:#fff;
border:1px solid #ccc;
}
blockquote {color:#567880;margin:0 35px 10px 18px;padding-left:8px;border-left:8px solid #CFDCDF;}

#sidebar .powered-by {
padding-top:15px;
padding-left:15px;
}

#sidebar .powered-by img {border:0;padding:0;margin:0;}

#sidebar-content .about img {
float:left;
margin-right:10px;
padding:5px;
background-color:#fff;
border:1px solid #ccc;
}

.paginate {
 font-family:		Verdana, Geneva, Tahoma, Trebuchet MS, Arial, Sans-serif;
 font-size:			12px;
 font-weight: 		normal;
 letter-spacing:	.1em;
 padding:			10px 6px 10px 4px;
 margin:			0;
 background-color:	transparent;
}

.pagecount {
 font-family:		Verdana, Geneva, Tahoma, Trebuchet MS, Arial, Sans-serif;
 font-size:			10px;
 color:				#666;
 font-weight:		normal;
 background-color: transparent;
}
<?php

$buffer = ob_get_contents();
ob_end_clean();
return $buffer;

}
// END



//-------------------------------------
//	Weblog index template
//-------------------------------------

function index()
{
	global $type;

ob_start();
?>
{assign_variable:my_weblog="default_site"}
{assign_variable:my_template_group="site"}
<!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="{lang}" lang="{lang}">
<head>
<title>{exp:weblog:info weblog="{my_weblog}"}{blog_title}{/exp:weblog:info}</title>

<meta http-equiv="Content-Type" content="text/html; charset={charset}" />

<link rel='stylesheet' type='text/css' media='all' href='{stylesheet={my_template_group}/site_css}' />
<style type='text/css' media='screen'>@import "{stylesheet={my_template_group}/site_css}";</style>


</head>

<body>



<div id="wrapper">


<div id="blog-header">
<div id="blog-header-text">
<h1>{exp:weblog:info weblog="{my_weblog}"}{blog_title}{/exp:weblog:info}</h1>
</div>

<div id="sidebar-top">

<div id="nav">
<a href="{site_url}">home</a> |
<a href="#">about</a> |
<a href="#">photos</a> |
<a href="#">archives</a> |
<a href="#">contact</a>
</div>

</div>

<br class="clear" />

</div>


<div id="content-wrapper">

<div id="content">




{exp:weblog:entries weblog="{my_weblog}" orderby="date" sort="desc" limit="15"}

{date_heading}
<h2 class="date-header">{entry_date format=' %l, %F %d, %Y'}</h2>
{/date_heading}


<div class="post">
<h3 class="post-header">{title}</h3>

<div class="post-summary">
{summary}
{body}
{extended}
</div>


<div class="post-details">

Posted by <?php if ($type != 'core') { ?>{author}<?php } else { ?><a href="{profile_path=member/index}">{author}</a><?php } ?>  in
{categories}
&#8226; <a href="{path=site_index}">{category_name}</a>
{/categories}
<br />
{if allow_comments}
({comment_total}) <a href="{url_title_path="{my_template_group}/comments"}">Comments</a> |
{/if}
{if allow_trackbacks}
({trackback_total}) <a href="{trackback_path="{my_template_group}/trackbacks"}">Trackbacks</a> |
{/if}
<a href="{title_permalink={my_template_group}/comments}">Permalink</a>

</div>


{paginate}
<div class="paginate">
<span class="pagecount">Page {current_page} of {total_pages} pages</span>  {pagination_links}
</div>
{/paginate}

</div>
<!-- end .post -->

{/exp:weblog:entries}






</div>

<div id="sidebar">

<div id="sidebar-content">



<?php if ($type != 'core') { ?>
<div class="sidebar-block">
<h3 class="sidebar-header first"> Members </h3>
<p>

{if logged_in}
 <a href="{path=member/profile}">Your Account</a>  |  <a href="{path=logout}">Logout</a>
{/if}

{if logged_out}
 <a href="{path=member/login}">Login</a> | <a href="{path=member/register}">Register</a>
{/if}

 | <a href="{path=member/memberlist}">Member List</a>

</p>
</div>
<?php } ?>


<br class="clear" />


<div class="sidebar-block about">

<h3 class="sidebar-header first">About</h3>
 <p>Quote meon an estimate et non interruptus stadium. Sic tempus fugit esperanto hiccup estrogen. </p>

</div>





<div class="sidebar-block">

<h3 class="sidebar-header">Search</h3>

{exp:search:simple_form search_in="everywhere"}
<p>
<input type="text" name="keywords" value="" class="input" size="18" maxlength="100" />
<br />
<input type="submit" value="submit"  class="submit" /></p>

<p><a href="{path=search/index}">Advanced Search</a></p>

{/exp:search:simple_form}

</div>



<div class="sidebar-block">
<h3 class="sidebar-header">Monthly Archives</h3>
<ul>
{exp:weblog:month_links weblog="{my_weblog}"}
<li><a href="{path={my_template_group}/index}">{month} {year}</a></li>
{/exp:weblog:month_links}
</ul>
</div>


<div class="sidebar-block">
<h3 class="sidebar-header">Categories</h3>
{exp:weblog:categories weblog="{my_weblog}" style="nested"}
<a href="{path={my_template_group}/index}">{category_name}</a>
{/exp:weblog:categories}
</div>


<div class="sidebar-block">
<h3 class="sidebar-header">Recent Entries</h3>
<ul>
{exp:weblog:entries orderby="date" sort="desc" limit="15" weblog="{my_weblog}" dynamic="off"}
<li><a href="{title_permalink={my_template_group}/comments}">{title}</a></li>
{/exp:weblog:entries}
</ul>
</div>


<div class="sidebar-block">
<ul>
<li class="sidebar-header">Syndicate</li>
<li><a href="{path={my_template_group}/rss_2.0}">RSS 2.0</a></li>
<li><a href="{path={my_template_group}/atom}">Atom</a></li>
</ul>
</div>


	</div>
	</div>

	<div class="clear"></div>

</div>
<!-- close #content-wrapper -->

<div id="blog-footer">
<a href="http://www.expressionengine.com">Powered by ExpressionEngine</a>
</div>

</div>
<!-- close #wrapper -->

</body>
</html>
<?php

$buffer = ob_get_contents();
ob_end_clean();
return $buffer;

}
// END






//-------------------------------------
// Comments
//-------------------------------------

function comments()
{
	global $type;

ob_start();
?>
{assign_variable:my_weblog="default_site"}
{assign_variable:my_template_group="site"}
<!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="{lang}" lang="{lang}">
<head>
<title>{exp:weblog:info weblog="{my_weblog}"}{blog_title}{/exp:weblog:info}</title>

<meta http-equiv="Content-Type" content="text/html; charset={charset}" />

<link rel='stylesheet' type='text/css' media='all' href='{stylesheet={my_template_group}/site_css}' />
<style type='text/css' media='screen'>@import "{stylesheet={my_template_group}/site_css}";</style>


</head>

<body>


<div id="wrapper">

<div id="blog-header">
<div id="blog-header-text">
<h1>{exp:weblog:info weblog="{my_weblog}"}{blog_title}{/exp:weblog:info}</h1>
</div>

<div id="sidebar-top">

<div id="nav">
<a href="{site_url}">home</a> |
<a href="#">about</a> |
<a href="#">photos</a> |
<a href="#">archives</a> |
<a href="#">contact</a>
</div>

</div>

<br class="clear" />

</div>


<div id="content-wrapper">

<div id="content">




{exp:weblog:entries limit="1"}

{date_heading}
<h2 class="date-header">{entry_date format=' %l, %F %d, %Y'}</h2>
{/date_heading}


<div class="post">
<h3 class="post-header">{title}</h3>

<div class="post-summary">
{summary}
{body}
{extended}
</div>


<div class="post-details">

Posted by <?php if ($type != 'core') { ?>{author}<?php } else { ?><a href="{profile_path=member/index}">{author}</a><?php } ?>  in
{categories}
&#8226; <a href="{path=site_index}">{category_name}</a>
{/categories}
<br />
{if allow_comments}
({comment_total}) <a href="{url_title_path="{my_template_group}/comments"}">Comments</a> |
{/if}
{if allow_trackbacks}
({trackback_total}) <a href="{trackback_path="{my_template_group}/trackbacks"}">Trackbacks</a> |
{/if}
<a href="{title_permalink={my_template_group}/comments}">Permalink</a>

</div>
</div>
{/exp:weblog:entries}


{exp:weblog:next_entry weblog="{my_weblog}"}
<span class="post-details">Next entry: <a href="{path={my_template_group}/comments}">{title}</a></span>
{/exp:weblog:next_entry}

{exp:weblog:prev_entry weblog="{my_weblog}"}
<span class="post-details">Previous entry: <a href="{path={my_template_group}/comments}">{title}</a></span>
{/exp:weblog:prev_entry}


<!-- start #comments-wrapper -->
<div id="comments-wrapper">



{exp:comment:entries weblog="{my_weblog}" limit="25"}
<div class="{switch='comment one|comment two'}">
<div class="comment-details">{url_or_email_as_author}  &nbsp;on&nbsp; {comment_date format='%m/%d'} &nbsp;at&nbsp; {comment_date format='%h:%i %A'}</div>
{comment}
</div>

{paginate}
<div class="paginate">
<span class="pagecount">Page {current_page} of {total_pages} pages</span>  {pagination_links}
</div>
{/paginate}
{/exp:comment:entries}





<!-- start #post-comment -->
  <div id="post-comment">

  <a name="post"></a>
  <h4>Post a comment</h4>


{exp:comment:form preview="{my_template_group}/comment_preview"}

{if logged_out}
<p>
Name:<br />
<input type="text" name="name" value="{name}" size="50" />
</p>
<p>
Email:<br />
<input type="text" name="email" value="{email}" size="50" />
</p>
<p>
Location:<br />
<input type="text" name="location" value="{location}" size="50" />
</p>
<p>
URL:<br />
<input type="text" name="url" value="{url}" size="50" />
</p>

{/if}

<p>
<a href="{path={my_template_group}/smileys}" onclick="window.open(this.href, '_blank', 'width=400,height=440');return false;" onkeypress="this.onclick()">Smileys</a>
</p>


<p>
<textarea name="comment" cols="50" rows="12" style="width:100%">{comment}</textarea>
</p>

{if logged_out}
<p><input type="checkbox" name="save_info" value="yes" {save_info} /> Remember my personal information</p>
{/if}

<p><input type="checkbox" name="notify_me" value="yes" {notify_me} /> Notify me of follow-up comments?</p>

{if captcha}
<p>Submit the word you see below:</p>
<p>
{captcha}
<br />
<input type="text" name="captcha" value="" size="20" maxlength="20" style="width:140px;" />
</p>
{/if}

<p><input type="submit" name="submit" value="Submit" />
<input type="submit" name="preview" value="Preview" /></p>

{/exp:comment:form}








</div>
<!-- end #post-comment -->





</div>
<!-- end #comments-wrapper -->




</div>

<div id="sidebar">

<div id="sidebar-content">



<?php if ($type != 'core') { ?>
<div class="sidebar-block">
<h3 class="sidebar-header first"> Members </h3>
<p>

{if logged_in}
 <a href="{path=member/profile}">Your Account</a>  |  <a href="{path=logout}">Logout</a>
{/if}

{if logged_out}
 <a href="{path=member/login}">Login</a> | <a href="{path=member/register}">Register</a>
{/if}

 | <a href="{path=member/memberlist}">Member List</a>

</p>
</div>
<?php } ?>


<br class="clear" />


<div class="sidebar-block about">

<h3 class="sidebar-header first">About</h3>
 <p>Quote meon an estimate et non interruptus stadium. Sic tempus fugit esperanto hiccup estrogen. </p>

</div>





<div class="sidebar-block">

<h3 class="sidebar-header">Search</h3>

{exp:search:simple_form search_in="everywhere"}
<p>
<input type="text" name="keywords" value="" class="input" size="18" maxlength="100" />
<br />
<input type="submit" value="submit"  class="submit" /></p>

<p><a href="{path=search/index}">Advanced Search</a></p>

{/exp:search:simple_form}

</div>



<div class="sidebar-block">
<h3 class="sidebar-header">Monthly Archives</h3>
<ul>
{exp:weblog:month_links weblog="{my_weblog}"}
<li><a href="{path={my_template_group}/index}">{month} {year}</a></li>
{/exp:weblog:month_links}
</ul>
</div>


<div class="sidebar-block">
<h3 class="sidebar-header">Categories</h3>
{exp:weblog:categories weblog="{my_weblog}" style="nested"}
<a href="{path={my_template_group}/index}">{category_name}</a>
{/exp:weblog:categories}
</div>


<div class="sidebar-block">
<h3 class="sidebar-header">Recent Entries</h3>
<ul>
{exp:weblog:entries orderby="date" sort="desc" limit="15" weblog="{my_weblog}" dynamic="off"}
<li><a href="{title_permalink={my_template_group}/comments}">{title}</a></li>
{/exp:weblog:entries}
</ul>
</div>


<div class="sidebar-block">
<ul>
<li class="sidebar-header">Syndicate</li>
<li><a href="{path={my_template_group}/rss_2.0}">RSS 2.0</a></li>
<li><a href="{path={my_template_group}/atom}">Atom</a></li>
</ul>
</div>


</div>
</div>

<div class="clear"></div>

</div>
<!-- close #content-wrapper -->

<div id="blog-footer">
<a href="http://www.expressionengine.com">Powered by ExpressionEngine</a>
</div>

</div>
<!-- close #wrapper -->

</body>
</html>
<?php

$buffer = ob_get_contents();
ob_end_clean();
return $buffer;

}
// END




//-------------------------------------
//	Comment preview
//-------------------------------------

function comment_preview()
{
	global $type;

ob_start();
?>
{assign_variable:my_weblog="default_site"}
{assign_variable:my_template_group="site"}
<!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="{lang}" lang="{lang}">
<head>
<title>{exp:weblog:info weblog="{my_weblog}"}{blog_title}{/exp:weblog:info}</title>

<meta http-equiv="Content-Type" content="text/html; charset={charset}" />

<link rel='stylesheet' type='text/css' media='all' href='{stylesheet={my_template_group}/site_css}' />
<style type='text/css' media='screen'>@import "{stylesheet={my_template_group}/site_css}";</style>


</head>

<body>


<div id="wrapper">

<div id="blog-header">
<div id="blog-header-text">
<h1>{exp:weblog:info weblog="{my_weblog}"}{blog_title}{/exp:weblog:info}</h1>
</div>

<div id="sidebar-top">

<div id="nav">
<a href="{site_url}">home</a> |
<a href="#">about</a> |
<a href="#">photos</a> |
<a href="#">archives</a> |
<a href="#">contact</a>
</div>

</div>

<br class="clear" />

</div>


<div id="content-wrapper">

<div id="content">




<!-- start #comments-wrapper -->
<div id="comments-wrapper">


{exp:comment:preview}
{comment}
{/exp:comment:preview}


<!-- start #post-comment -->
  <div id="post-comment">

  <a name="post"></a>
  <h4>Post a comment</h4>


{exp:comment:form preview="{my_template_group}/comment_preview"}

{if logged_out}
<p>
Name:<br />
<input type="text" name="name" value="{name}" size="50" />
</p>
<p>
Email:<br />
<input type="text" name="email" value="{email}" size="50" />
</p>
<p>
Location:<br />
<input type="text" name="location" value="{location}" size="50" />
</p>
<p>
URL:<br />
<input type="text" name="url" value="{url}" size="50" />
</p>

{/if}

<p>
<a href="{path={my_template_group}/smileys}" onclick="window.open(this.href, '_blank', 'width=400,height=440');return false;" onkeypress="this.onclick()">Smileys</a>
</p>


<p>
<textarea name="comment" cols="50" rows="12" style="width:100%">{comment}</textarea>
</p>

{if logged_out}
<p><input type="checkbox" name="save_info" value="yes" {save_info} /> Remember my personal information</p>
{/if}

<p><input type="checkbox" name="notify_me" value="yes" {notify_me} /> Notify me of follow-up comments?</p>

{if captcha}
<p>Submit the word you see below:</p>
<p>
{captcha}
<br />
<input type="text" name="captcha" value="" size="20" maxlength="20" style="width:140px;" />
</p>
{/if}

<p><input type="submit" name="submit" value="Submit" />
<input type="submit" name="preview" value="Preview" /></p>

{/exp:comment:form}



</div>
<!-- end #post-comment -->



</div>
<!-- end #comments-wrapper -->


</div>

<div id="sidebar">

<div id="sidebar-content">



<?php if ($type != 'core') { ?>
<div class="sidebar-block">
<h3 class="sidebar-header first"> Members </h3>
<p>

{if logged_in}
 <a href="{path=member/profile}">Your Account</a>  |  <a href="{path=logout}">Logout</a>
{/if}

{if logged_out}
 <a href="{path=member/login}">Login</a> | <a href="{path=member/register}">Register</a>
{/if}

 | <a href="{path=member/memberlist}">Member List</a>

</p>
</div>
<?php } ?>


<br class="clear" />


<div class="sidebar-block about">

<h3 class="sidebar-header first">About</h3>
 <p>Quote meon an estimate et non interruptus stadium. Sic tempus fugit esperanto hiccup estrogen. </p>

</div>



<div class="sidebar-block">

<h3 class="sidebar-header">Search</h3>

{exp:search:simple_form search_in="everywhere"}
<p>
<input type="text" name="keywords" value="" class="input" size="18" maxlength="100" />
<br />
<input type="submit" value="submit"  class="submit" /></p>

<p><a href="{path=search/index}">Advanced Search</a></p>

{/exp:search:simple_form}

</div>



<div class="sidebar-block">
<h3 class="sidebar-header">Monthly Archives</h3>
<ul>
{exp:weblog:month_links weblog="{my_weblog}"}
<li><a href="{path={my_template_group}/index}">{month} {year}</a></li>
{/exp:weblog:month_links}
</ul>
</div>


<div class="sidebar-block">
<h3 class="sidebar-header">Categories</h3>
{exp:weblog:categories weblog="{my_weblog}" style="nested"}
<a href="{path={my_template_group}/index}">{category_name}</a>
{/exp:weblog:categories}
</div>


<div class="sidebar-block">
<h3 class="sidebar-header">Recent Entries</h3>
<ul>
{exp:weblog:entries orderby="date" sort="desc" limit="15" weblog="{my_weblog}" dynamic="off"}
<li><a href="{title_permalink={my_template_group}/comments}">{title}</a></li>
{/exp:weblog:entries}
</ul>
</div>


<div class="sidebar-block">
<ul>
<li class="sidebar-header">Syndicate</li>
<li><a href="{path={my_template_group}/rss_2.0}">RSS 2.0</a></li>
<li><a href="{path={my_template_group}/atom}">Atom</a></li>
</ul>
</div>


</div>
</div>

<div class="clear"></div>

</div>
<!-- close #content-wrapper -->

<div id="blog-footer">
<a href="http://www.expressionengine.com">Powered by ExpressionEngine</a>
</div>

</div>
<!-- close #wrapper -->

</body>
</html>
<?php

$buffer = ob_get_contents();
ob_end_clean();
return $buffer;

}
// END





//-------------------------------------
//	Trackbacks
//-------------------------------------

function trackbacks()
{
	global $type;

ob_start();
?>
{assign_variable:my_weblog="default_site"}
{assign_variable:my_template_group="site"}
<!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="{lang}" lang="{lang}">
<head>
<title>{exp:weblog:info weblog="{my_weblog}"}{blog_title}{/exp:weblog:info}</title>

<meta http-equiv="Content-Type" content="text/html; charset={charset}" />

<link rel='stylesheet' type='text/css' media='all' href='{stylesheet={my_template_group}/site_css}' />
<style type='text/css' media='screen'>@import "{stylesheet={my_template_group}/site_css}";</style>


</head>

<body>


<div id="wrapper">

<div id="blog-header">
<div id="blog-header-text">
<h1>{exp:weblog:info weblog="{my_weblog}"}{blog_title}{/exp:weblog:info}</h1>
</div>

<div id="sidebar-top">

<div id="nav">
<a href="{site_url}">home</a> |
<a href="#">about</a> |
<a href="#">photos</a> |
<a href="#">archives</a> |
<a href="#">contact</a>
</div>

</div>

<br class="clear" />

</div>


<div id="content-wrapper">

<div id="content">


<p>The trackback URL for this entry is:</p>
<form action="">
<p><input type="text" value="{exp:trackback:url}" size="40" class="input" style="width:99%" /></p>
</form>



<!-- start #comments-wrapper -->
<div id="comments-wrapper">


{exp:trackback:entries}
<div class="{switch='comment one|comment two'}">

{if no_results}
<p>There are no trackbacks for this entry</p>
{/if}

<h2>{title}</h2>
{content}
<div class="comment-details">Tracked on: <a href="{trackback_url}">{weblog_name}</a> ({trackback_ip}) at {trackback_date format="%Y %m %d %H:%i:%s"}</div>

</div>

{/exp:trackback:entries}


</div>
<!-- end #comments-wrapper -->


</div>

<div id="sidebar">

<div id="sidebar-content">



<?php if ($type != 'core') { ?>
<div class="sidebar-block">
<h3 class="sidebar-header first"> Members </h3>
<p>

{if logged_in}
 <a href="{path=member/profile}">Your Account</a>  |  <a href="{path=logout}">Logout</a>
{/if}

{if logged_out}
 <a href="{path=member/login}">Login</a> | <a href="{path=member/register}">Register</a>
{/if}

 | <a href="{path=member/memberlist}">Member List</a>

</p>
</div>
<?php } ?>


<br class="clear" />


<div class="sidebar-block about">

<h3 class="sidebar-header first">About</h3>
 <p>Quote meon an estimate et non interruptus stadium. Sic tempus fugit esperanto hiccup estrogen. </p>

</div>



<div class="sidebar-block">

<h3 class="sidebar-header">Search</h3>

{exp:search:simple_form search_in="everywhere"}
<p>
<input type="text" name="keywords" value="" class="input" size="18" maxlength="100" />
<br />
<input type="submit" value="submit"  class="submit" /></p>

<p><a href="{path=search/index}">Advanced Search</a></p>

{/exp:search:simple_form}

</div>



<div class="sidebar-block">
<h3 class="sidebar-header">Monthly Archives</h3>
<ul>
{exp:weblog:month_links weblog="{my_weblog}"}
<li><a href="{path={my_template_group}/index}">{month} {year}</a></li>
{/exp:weblog:month_links}
</ul>
</div>


<div class="sidebar-block">
<h3 class="sidebar-header">Categories</h3>
{exp:weblog:categories weblog="{my_weblog}" style="nested"}
<a href="{path={my_template_group}/index}">{category_name}</a>
{/exp:weblog:categories}
</div>


<div class="sidebar-block">
<h3 class="sidebar-header">Recent Entries</h3>
<ul>
{exp:weblog:entries orderby="date" sort="desc" limit="15" weblog="{my_weblog}" dynamic="off"}
<li><a href="{title_permalink={my_template_group}/comments}">{title}</a></li>
{/exp:weblog:entries}
</ul>
</div>


<div class="sidebar-block">
<ul>
<li class="sidebar-header">Syndicate</li>
<li><a href="{path={my_template_group}/rss_2.0}">RSS 2.0</a></li>
<li><a href="{path={my_template_group}/atom}">Atom</a></li>
</ul>
</div>


</div>
</div>

<div class="clear"></div>

</div>
<!-- close #content-wrapper -->

<div id="blog-footer">
<a href="http://www.expressionengine.com">Powered by ExpressionEngine</a>
</div>

</div>
<!-- close #wrapper -->

</body>
</html>
<?php

$buffer = ob_get_contents();
ob_end_clean();
return $buffer;

}
// END




//-------------------------------------
//	Smileys
//-------------------------------------

function smileys()
{
	global $type;

ob_start();
?>
<!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" xml:lang="{lang}" lang="{lang}">
<head>
<meta http-equiv="content-type" content="text/html; charset={charset}" />
<title>Smileys</title>

<style type="text/css">

body {
 background-color: #ffffff;
 margin-left: 40px;
 margin-right: 40px;
 margin-top: 30px;
 font-size: 11px;
 font-family: verdana,trebuchet,sans-serif;
}
a:link {
 color: #990000;
 font-size: 11px;
 font-weight: normal;
 text-decoration: underline;
}
a:visited {
 color: #990000;
 font-size: 11px;
 font-weight: normal;
 text-decoration: underline;
}
a:active {
 color: #990000;
 font-size: 11px;
 font-weight: normal;
 text-decoration: underline;
}
a:hover {
 color: #990000;
 font-size: 11px;
 font-weight: normal;
 text-decoration: none;
}

</style>

<script language="javascript">
<!--

function add_smiley(smiley)
{
    opener.document.comment_form.comment.value += " " + smiley + " ";
    opener.window.document.comment_form.comment.focus();
    window.close();
}
//-->
</script>


</head>
<body>

<p>Click on an image to add it to your comment</p>

<table border="0" width="100%" cellpadding="6" cellspacing="1">

{exp:emoticon columns="4"}
<tr>
<td><div>{smiley}</div></td>
</tr>
{/exp:emoticon}

</table>

</body>
</html>
<?php

$buffer = ob_get_contents();
ob_end_clean();
return $buffer;

}
// END


//-------------------------------------
//	Default referrers
//-------------------------------------

function referrers()
{
	global $type;

ob_start();
?>
<!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" xml:lang="{lang}" lang="{lang}">

<head>
<meta http-equiv="content-type" content="text/html; charset={charset}" />
<title>Referrers</title>

<style type="text/css">

body {
 background-color: #ffffff;
 margin-left: 40px;
 margin-right: 40px;
 margin-top: 30px;
 font-size: 11px;
 font-family: verdana,trebuchet,sans-serif;
}
h4 {
 font-size: 14px;
 font-family: verdana,trebuchet,sans-serif;
}
a:link {
 color: #990000;
 font-size: 11px;
 font-weight: normal;
 text-decoration: underline;
}
a:visited {
 color: #990000;
 font-size: 11px;
 font-weight: normal;
 text-decoration: underline;
}
a:active {
 color: #990000;
 font-size: 11px;
 font-weight: normal;
 text-decoration: underline;
}
a:hover {
 color: #990000;
 font-size: 11px;
 font-weight: normal;
 text-decoration: none;
}

</style>

</head>
<body>

<h4>Referrers</h4>

<table border="0" width="100%" cellpadding="6" cellspacing="1">
<tr>
<td>From</td>
<td>To</td>
<td>IP Address</td>
<td>Date</td>
</tr>

{exp:referrer limit="50" popup="yes"}
<tr class="row">
<td><div>{ref_from}</div></td>
<td><div>{ref_to}</div></td>
<td><div>{ref_ip}</div></td>
<td><div>{ref_date format="%m/%d/%Y"}</div></td>
</tr>
{/exp:referrer}

</table>

</body>
</html>
<?php

$buffer = ob_get_contents();
ob_end_clean();
return $buffer;

}
// END
?>