Managing a specific connection
Posted: Tue Aug 31, 2010 10:32 am
In my small project, when users are registering they select the day in which were born and then using Zeller's congruence I record in my database what day is it.
On the other hand, I want that if a user log in the same day that he was born automatically increases one field of the user, therefore, if he return to log in the same day it doesn't increase.
I have been thinking to put a mark in the day recorded in DB in the first connection if the day match and then when the day change return to set the day correctly do you think it could work.
=====
Another question no related with this: when you use mysql do you always finish with the mysql_close and mysql_free_result?¿
Thank you very much.
On the other hand, I want that if a user log in the same day that he was born automatically increases one field of the user, therefore, if he return to log in the same day it doesn't increase.
I have been thinking to put a mark in the day recorded in DB in the first connection if the day match and then when the day change return to set the day correctly do you think it could work.
=====
Another question no related with this: when you use mysql do you always finish with the mysql_close and mysql_free_result?¿
Thank you very much.