+ added jquery.js for future code highlight
[vsc.git] / _pages / display / pages / main.tpl
blob4143acce204348c3876258977b50b18d0c69ca42
1         <h1><a href="{$main}">{$title|ucwords|spacify}</a></h1>
2         <div id="contents">
3                 <form action='{$search}' method="post">
4                 <fieldset style="text-align:center">
5                         <legend style="margin-bottom:0.2em"><button type="submit">Search</button></legend>
6                         <input type="text" name="search" id="search" value="" style="font-size:1.1em; width:97%" />
7                 </fieldset>
8                 </form>
9 {if $posts neq ''}
10         Contents:
11                 <ol>
12 {foreach from=$posts item=post}
13                         <li> <a href="#p{$post.post_id}">{$post.post_title|ucfirst}</a> </li>
14 {/foreach}
15                 </ol>
16 {/if}
17         </div>
18 {if $posts neq ''}
19         <ul id="p">
20 {foreach from=$posts item=post}
21                 <li class='post'>
22                         <div class='head' id='p{$post.post_id}'><h2>{$post.post_title|ucfirst|strip}</h2>
23 {if $post.post_time neq ''}
24                                 <span class="details">
25                                         Posted by <strong>{$post.user_name}</strong> in: <strong>{$post.category_name}</strong><br/>
26                                          on {$post.post_time|date_format:"%c - %Z"}
27                                 </span>
28 {/if}
29                         </div>
30                         <div class='main'>
31                                 {$post.post_body|strip}
32                         </div>
33                         <div class="cleaner"></div>
34                         <ul class='tail'>
35                                 {if $post.eaction neq ''}<li>[ <a href="{$post.eaction}" class="act">edit</a> ]</li>{/if}
36                                 <li> [ <a href="{$post.addaction}" class="act">comment</a> ]</li>
37                         </ul>
38                 </li>
39 {/foreach}
40         </ul>
41 {/if}
42         <div class="cleaner"></div>
43         <!-- 
44         <ul id='size'>
45 {literal}
46                 <script type="text/javascript">
47                         function resize () {
48                                 alert (document.getElementsByTagName('body').item(0).fontSize);
49                                 document.getElementsByTagName('html').item(0).style.fontSize =  '80%';
50                                 return false;
51                         }
52                 </script>
53 {/literal}
54                 <li id='s1'><a onclick="resize()" href='#s1'>A</a></li>
55                 <li id='s2'><a onclick="document.getElementsByTagName('html').item(0).style.fontSize = '100%';return false" href='#s2'>A</a></li>
56                 <li id='s3'><a onclick="document.getElementsByTagName('html').item(0).style.fontSize = '120%';return false" href='#s3'>A</a></li>
57         </ul>
58          -->