I want to php script for Like/Dislike button ?

Status
Not open for further replies.
I'm not going to give you the code cuz you're obviously super lazy and demanding. But I'll give you some tips.

This is better off as an ajax script, but here is how you would do it in just PHP.

Assuming you want users to like posts on a blog, create a column in your MySQL 'posts' table called 'like' and put a link on your post called 'like'. When they click it, send them to a script that runs the MySQL query to update that post and change the 'like' field to 'yes'. Now on your post, use mysql_num_rows to count how many likes it has.

Hope this helps.

If you're looking for a fb like script then you obviously haven't done a google search at all cuz there's 20 million pages about it.
 
Status
Not open for further replies.
Back
Top