function getSidebar() { $posts = $sidebar = ' <div class="container-aside quiet"> <h4 style="margin-bottom: .5em;" class="loud">Want another bite? Subscribe!</h4> <p><a href="http://feeds.feedburner.com/kennethreitz" target="_none">RSS</a>, <a href="http://feedburner.google.com/fb/a/mailverify?uri=kennethreitz&loc=en_US" target="_none">Email</a>, <a href="http://friendfeed.com/kennethreitz" target="_none">FriendFeed</a>, <a href="http://twitter.com/kennethreitz" target="_none">Twitter</a>, <a href="http://www.facebook.com/pages/KennethReitzcom/144095770952?ref=ts" target="_none">Facebook</a>.<br/> If you see something that makes you shake with excitment or surge with rage, leave a comment and <a href="javascript:var%20e=document.createElement(\'script\');e.setAttribute(\'language\',\'javascript\');e.setAttribute(\'src\',\'http://bit.ly/bookmarklet/load.js\');document.body.appendChild(e);void(0);">send a link</a> to others!</p> <hr/> <h4 class="loud">About @KennethReitz</h4> <p> <strong>Kenneth Reitz, <em>n</em></strong>: Open Mind. Open Source.<br/> <strong>Location?</strong> Winchester, Virginia. <br/> <strong>Field?</strong> Web Application Development <br/> <strong>What??</strong> I make websites.<br/> <strong>Language? </strong> Python. <em>Everything</em> else.<br/> <strong>Tools?</strong> MacBook + iPhone + Moleskine = 42.<br/> <strong>Anything Else?</strong> Life is wonderful.</p> <hr/> <h4>Latest Posts</h4>'; echo $sidebar; echo wp_get_archives('format=custom&after=… &type=postbypost&limit=15&show_post_count=false'); echo '<hr/>'; echo '<p class="extra-quiet">'; echo fortune(3000); echo '<p>'; echo '</div></div>'; }
$category_cn = "命理"; break; } $data["category_cn"] = $category_cn; $data["sex"] = $_POST["X2"]; $data["uid"] = $_SESSION["uid"]; $data["addtime"] = time(); $data["result"] = trim($html); //echo json_encode($testJSON); foreach ($_POST as $key => $value) { $_POST[$key] = urlencode($value); } $data["json"] = urldecode(json_encode($_POST)); $new = ORM::for_table(table("fotrune"))->create($data); $rs = $new->save(); fortune($_SESSION['uid'], $_SESSION['username'], $new->id, 2); if ($rs) { header("Location: ?act=fotrune_show&id=" . $new->id); } else { showmsg("测算失败", 2); } } elseif ($act == 'fotrune_show') { require_once QISHI_ROOT_PATH . 'genv/lib.php'; global $db; $id = $_GET["id"]; $sql = "select * from " . table("fotrune") . " where id=" . $id; $rs = ORM::for_table(table("fotrune"))->find_one($id); if (!$rs) { showmsg("没找到测算记录", 2); } $rs = $rs->as_array();
<div id="footer" class="container"> <hr/> <p>© Copyright <?php echo date("Y"); ?> <a href="mailto:admin@kennethreitz.com">Kenneth Reitz</a>. Life is good. <span id="fortune" class="quiet right"><?php echo fortune(); ?> </span></p> </div> <!-- Script Stuff --> <script type="text/javascript" src="<?php bloginfo('template_url'); ?> /lib/js/modernizr-0.9.min.js"></script> <script type="text/javascript" src="<?php bloginfo('template_url'); ?> /lib/js/jquery.min.js"></script> <script type="text/javascript" src="<?php bloginfo('template_url'); ?> /lib/js/slimbox2.js"></script> <!-- // <script src="http://tweetboard.com/tb.js?v=1.0&user=kennethreitz" type="text/javascript"></script> --> <script type="text/javascript"> // $(function() { // $('#photostream a').lightBox(); // });