From b8b227b32882fb511c8481a41c53637e7ce7707a Mon Sep 17 00:00:00 2001 From: Mike Macgirvin Date: Sat, 23 Oct 2010 01:20:26 -0700 Subject: add nicknames to contact records (going forward and retroactive) --- include/Scrape.php | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'include/Scrape.php') diff --git a/include/Scrape.php b/include/Scrape.php index b4a5dd849..0272dde12 100644 --- a/include/Scrape.php +++ b/include/Scrape.php @@ -33,6 +33,11 @@ function scrape_dfrn($url) { $x = $item->getAttribute('rel'); if(substr($x,0,5) == "dfrn-") $ret[$x] = $item->getAttribute('href'); + if($x === 'lrdd') { + $decoded = urldecode($item->getAttribute('href')); + if(preg_match('/acct:([^@]*)@/',$decoded,$matches)) + $ret['nick'] = $matches[1]; + } } // Pull out hCard profile elements -- cgit v1.2.3