I need to create a simple automatic daily function to set my database columns to 0.
I know how to do with UPDATE
using mysql query.
I need to know how set an automatic function without using refresh, Java or other. I don't want to refresh page every xx seconds/min/h. I need this function to start at 8 am.
This because i need to change all my customers column and set to 0 daily access.
I'm using php, html and a mysql database. Same story with a 1ST day month cron. I need to reset all to 0 every 1st day of each month (automatically).
I want to use this cron also for activate my web page only from 10 am to 3pm, don't ask me why, i'm doing examples.
I already read other topic but i don't know how write code for cron, i m a beginner. I found this: 00 08 * * 1 php --q directory/cron.php Maybe it runs every MONDAY something.... right... but how can i set my function to start all every day using *** ok but please explain me how to run functions and where i should write them.