diff options
author | Friendika <info@friendika.com> | 2011-07-18 18:13:46 -0700 |
---|---|---|
committer | Friendika <info@friendika.com> | 2011-07-18 18:13:46 -0700 |
commit | c0b8e63a3fe600326e0f18c03207ba9fd30c8126 (patch) | |
tree | a3eb8d1f518066101b881738d5f678c4d3a01d46 /boot.php | |
parent | 25b4aacf3b53d4f82f7dc817bb1e022b2a61c1a3 (diff) | |
download | volse-hubzilla-c0b8e63a3fe600326e0f18c03207ba9fd30c8126.tar.gz volse-hubzilla-c0b8e63a3fe600326e0f18c03207ba9fd30c8126.tar.bz2 volse-hubzilla-c0b8e63a3fe600326e0f18c03207ba9fd30c8126.zip |
basic diaspora discovery
Diffstat (limited to 'boot.php')
-rw-r--r-- | boot.php | 14 |
1 files changed, 13 insertions, 1 deletions
@@ -2,7 +2,7 @@ define ( 'FRIENDIKA_VERSION', '2.2.1045' ); define ( 'DFRN_PROTOCOL_VERSION', '2.21' ); -define ( 'DB_UPDATE_VERSION', 1075 ); +define ( 'DB_UPDATE_VERSION', 1076 ); define ( 'EOL', "<br />\r\n" ); define ( 'ATOM_TIME', 'Y-m-d\TH:i:s\Z' ); @@ -2957,3 +2957,15 @@ function return_bytes ($size_str) { } }} +function generate_guid() { + $found = true; + do { + $guid = substr(random_string(),0,16); + $x = q("SELECT `uid` FROM `user` WHERE `guid` = '%s' LIMIT 1", + dbesc($guid) + ); + if(! count($x)) + $found = false; + } while ($found == true ); + return $guid; +}
\ No newline at end of file |