I'm creating a website that will be updated with contributor posts, comments, etc, etc and I'm wondering the best way of creating the id's to prevent there ever being a duplicate in ANY of the tables. I'm using a timestamp at the moment along with a unique number at the end, like:
$time = time();
$id= time().'-'.mt_rand(1000, 9999);
To Output:
1378291391-1167, 1378294733-8990, 1378294934-3336, etc, etc, etc.
Can anyone see a problem with this type of id creation system?