AVS user AGE fix

Discuss of AVS script, custom modifications or anything related to this video script

AVS user AGE fix

Postby nuevolab » Wed Oct 20, 2010 11:18 pm

If user edit his profile and doesn't change birth date his age aways will be 11 :D
Here's a tip how to fix it:

Go to your PhpMyAdmin, select your database, click "signup" table, click "structure" link from top menu.
Edit table field "bdate". Change default date from 0000-00-00 to 1901-01-01

Edit file "include/function_smarty.php" and find the line:
Code: Select all
if ( $year != '0000') {

Change it to:
Code: Select all
if ( $year != '0000' && $year !='1901' ) {

This will prevent from displaying "stupid" age if year is "1901" (default, not changed)

Good luck.
nuevolab
Site Admin
 
Posts: 99
Joined: Sun Sep 06, 2009 2:32 am

Return to AVS

Who is online

Users browsing this forum: No registered users and 0 guests

cron