Hi I would like to post some data to a db when certain categories are selected in a WP post. I would like this to action when the post is made.
This is the query I wan to run:
mysqli_query($con,"UPDATE persons SET Age=Age+1
WHERE FirstName='Peter' AND LastName='Griffin'");
and I want it to happen upon the publishing of the post and only when categories with id's 2 and 3 are both selected.
I've been trying for days now to get this right it's a little over my head. Any help would be greatly appreciated. Thankyou