function get_slot() { global $conf; $len = 7; $chars = "abcdefghijkmnopqrstuvwxyz0123456789"; $i = 0; $slot = '' ; while ($i < $len) { $num = rand(0, strlen($chars)); $tmp = substr($chars, $num, 1); $slot = $slot . $tmp; $i++; } return $slot; }