Help please.

Please am pretty struggling with some script… am pretty new to php… Is there an mysql function that will fetch the first row of the database/table and then mark it as read or set it’s visibility to 0 or off.This function will skip any row who’s visibility is marked off and echo out first row of the table that marks visible.

Thanks.

No,

you will need to create a field in your table called something like is_read, with a default of 0,

then when you display it you can update it to one

[php]$query=("update table set is_read=‘1’ where post_id = ‘$post_id’)[/php]

Then when you want to display ones which have not been shown,

[php]$query=mysql_query("SELECT * FROM table WHERE is_read=‘0’[/php]

That should get you going

Sponsor our Newsletter | Privacy Policy | Terms of Service