Welcome, guest! Login / Register - Why register?
Psst.. new poll here.
Psst.. new forums here.
Microsoft is blocking us again (TY IP Reputation!) so just use oauth login instead. :)

Paste

Pasted by mephisto ( 14 years ago )
protected static function _getUniqueId($type) {
  static $ids = array();
  
  $i = 0;
  
  do {
   $id = $type . ($i > 0 ? $i : '');
   $i++; 
  } while (in_array($id, $ids));
  
  $ids[] = $id;
  
  return $id;
 }

 

Revise this Paste

Your Name: Code Language: