//just for database connection require_once('./includes/base.php');
if($_GET['logout'] == 1){ @$_SESSION = array(); @session_unregister($_SESSION['userID']); @session_unregister($_SESSION['userName']); @session_unregister($_SESSION['userUser']); @session_unregister($_SESSION['userPass']); @session_destroy(); } // Display header require("./templates/$template/header.php");
?>
ob_start(); if(!empty($_SESSION['userID']) and !empty($_POST['user'])){ echo ''; } ?>
Hello world sub heading is blah, blah, blah!
$sql = mysql_query("SELECT users.userUser, posts.postID, posts.postPost, posts.postTime, posts.postComments, userAvatar FROM users, posts WHERE users.userID = posts.postUserID ORDER BY posts.postTime DESC "); while($row = mysql_fetch_array($sql)){ $abcd= $row['userName']; $abcd = str_replace (" ", "-", $abcd); $time = reltime($row['postTime']); echo '  | '.$row['postPost'].' Posted by: '.$row['userUser'].', Comments '.$row['postComments'].' , Time elapsed: '.$time.' | ';} ?>
echo '' ;
?>
$sql = mysql_query("SELECT users.userUser, links.linksID, links.linksLink, links.linksPost, links.linksTime, links.linksComments,userAvatar FROM users, links WHERE users.userID = links.linksUserID ORDER BY links.linksTime DESC"); while($row = mysql_fetch_array($sql)){ $abcd= $row['userName']; $abcd = str_replace (" ", "-", $abcd); $time1 = reltime($row['linksTime']); echo '  | '.$row['linksPost'].' Posted by: '.$row['userUser'].', Comments '.$row['linksComments'].' , Time elapsed: '.$time1.' | ';} ?>
echo '' ; ?> // testing grabimages('SELECT users.userUser, images.imagesID, images.imagesFile, images.imagesPost, images.imagesTime, images.imagesComments FROM users, images WHERE users.userID = images.imagesUserID ORDER BY images.imagesTime DESC LIMIT 20'); ?>
// Display footer require("./templates/$template/footer.php"); ?>
|
venu APosted Oct 1, 2009, 8:31 AM
Thanks anyway. Learned something new as a self taught prgrammer.
TrinityPosted Sep 27, 2009, 11:46 AM