Provides various official and user-released code examples. For code reference, you are welcome to exchange and learn the random and unique ID php function with the shortest digits. this can be used for the superconnections we receive on our daily mobile phones, for example, XXXXXX. CLICK: http://xxxx.com/user.php/m/o/ I /n.bcuf1bbb.
The php function that generates the shortest random and unique ID. It can be used for text message superconnections received on our daily mobile phones. For example, for details about XXXXXX, click http://xxxx.com/user.php/m/o/ I /n.bcuf1b.
Bcuf1b
// Author: copper peas
// QQ: 309581329
// Email: bestphper@126.com
// Http://gongwen.sinaapp.com
Function getRandOnlyId (){
// The New Time cut definition is based on the timestamp.
$ Endtime = 1356019200; // 2012-12-21 Timestamp
$ Curtime = time (); // current Timestamp
$ Newtime = $ curtime-$ endtime; // new Timestamp
$ Rand = rand (); // two random
$ All = $ rand. $ newtime;
$ Onlyid = base_convert ($ all, 10, 36); // the unique ID that converts 10 to 36.
Return $ onlyid;
}
// Obtain the random unique id
Echo getRandOnlyId ();
?>
AD: truly free, domain name + VM + enterprise mailbox = 0 RMB