Call a function each 10 days and an other each 30 days

Call a function each 10 days and an other each 30 days

Hi, how to call a function each 10 days ?  and an other one each 30 days ?

  1. function run_each_10_days() {
  2.       alert("10 days was left since last call!");
  3. }

  4. function run_each_30_days() {
  5.       alert("30 days was left since last call!");
  6. }

The two function should remain showing the alert for all the 24 hours of that day, when if complete 10 days for the first case, and when it complete 30 days for the second.

Thank you.