steviez Posted January 29, 2008 Share Posted January 29, 2008 Hi, I am trying to get my site to show when someone has posted a comment, with the code i have done even if its been read it still shows new. Here is my code: <?php // Check For New Comments $query = "SELECT profilecomment_id FROM se_profilecomments WHERE read_status='0' AND profilecomment_user_id='" . $user->user_info[user_id] . "'"; $result = mysql_query($query); $num_rows = mysql_num_rows($result); if($num_rows){ $smarty->assign("new_comments", "1"); } ?> and on my page i have: [code] {if $new_comments eq "1"} do this {/if} any ideas? [/code] Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.