aboutsummaryrefslogtreecommitdiffstats
path: root/mod
diff options
context:
space:
mode:
authorFriendika <info@friendika.com>2011-11-01 16:08:07 -0700
committerFriendika <info@friendika.com>2011-11-01 16:08:07 -0700
commit573670fa0c8a3d8f111430985d263499b79a6ac0 (patch)
tree901718877c62abe3d6cc3bfb2050fa6a5126dac3 /mod
parentae7425dadb2e8e2911f405631e332965066a916b (diff)
downloadvolse-hubzilla-573670fa0c8a3d8f111430985d263499b79a6ac0.tar.gz
volse-hubzilla-573670fa0c8a3d8f111430985d263499b79a6ac0.tar.bz2
volse-hubzilla-573670fa0c8a3d8f111430985d263499b79a6ac0.zip
more social graph stuff
Diffstat (limited to 'mod')
-rw-r--r--mod/dfrn_request.php12
-rw-r--r--mod/follow.php5
-rw-r--r--mod/register.php8
3 files changed, 15 insertions, 10 deletions
diff --git a/mod/dfrn_request.php b/mod/dfrn_request.php
index af4a5aece..9755895ce 100644
--- a/mod/dfrn_request.php
+++ b/mod/dfrn_request.php
@@ -142,12 +142,13 @@ function dfrn_request_post(&$a) {
* Create a contact record on our site for the other person
*/
- $r = q("INSERT INTO `contact` ( `uid`, `created`,`url`, `name`, `nick`, `photo`, `site-pubkey`,
+ $r = q("INSERT INTO `contact` ( `uid`, `created`,`url`, `nurl`, `name`, `nick`, `photo`, `site-pubkey`,
`request`, `confirm`, `notify`, `poll`, `poco`, `network`, `aes_allow`)
- VALUES ( %d, '%s', '%s', '%s' , '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', %d)",
+ VALUES ( %d, '%s', '%s', '%s', '%s' , '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', %d)",
intval(local_user()),
datetime_convert(),
dbesc($dfrn_url),
+ dbesc(normalise_link($dfrn_url)),
$parms['fn'],
$parms['nick'],
$parms['photo'],
@@ -371,12 +372,13 @@ function dfrn_request_post(&$a) {
dbesc_array($parms);
- $r = q("INSERT INTO `contact` ( `uid`, `created`, `url`, `name`, `nick`, `issued-id`, `photo`, `site-pubkey`,
+ $r = q("INSERT INTO `contact` ( `uid`, `created`, `url`, `nurl`,`name`, `nick`, `issued-id`, `photo`, `site-pubkey`,
`request`, `confirm`, `notify`, `poll`, `poco`, `network` )
- VALUES ( %d, '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s' )",
+ VALUES ( %d, '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s' )",
intval($uid),
- datetime_convert(),
+ dbesc(datetime_convert()),
$parms['url'],
+ dbesc(normalise_link($parms['url'])),
$parms['fn'],
$parms['nick'],
$parms['issued-id'],
diff --git a/mod/follow.php b/mod/follow.php
index 4328e7fe0..0329d1eee 100644
--- a/mod/follow.php
+++ b/mod/follow.php
@@ -100,12 +100,13 @@ function follow_post(&$a) {
$new_relation = CONTACT_IS_FOLLOWER;
// create contact record
- $r = q("INSERT INTO `contact` ( `uid`, `created`, `url`, `addr`, `alias`, `batch`, `notify`, `poll`, `poco`, `name`, `nick`, `photo`, `network`, `pubkey`, `rel`, `priority`,
+ $r = q("INSERT INTO `contact` ( `uid`, `created`, `url`, `nurl`, `addr`, `alias`, `batch`, `notify`, `poll`, `poco`, `name`, `nick`, `photo`, `network`, `pubkey`, `rel`, `priority`,
`writable`, `blocked`, `readonly`, `pending` )
- VALUES ( %d, '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', %d, %d, %d, 0, 0, 0 ) ",
+ VALUES ( %d, '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', %d, %d, %d, 0, 0, 0 ) ",
intval(local_user()),
dbesc(datetime_convert()),
dbesc($ret['url']),
+ dbesc(normalise_link($ret['url'])),
dbesc($ret['addr']),
dbesc($ret['alias']),
dbesc($ret['batch']),
diff --git a/mod/register.php b/mod/register.php
index 85e1f9faa..6ebe35dbf 100644
--- a/mod/register.php
+++ b/mod/register.php
@@ -268,9 +268,9 @@ function register_post(&$a) {
intval($newuid));
return;
}
- $r = q("INSERT INTO `contact` ( `uid`, `created`, `self`, `name`, `nick`, `photo`, `thumb`, `micro`, `blocked`, `pending`, `url`,
- `request`, `notify`, `poll`, `confirm`, `name-date`, `uri-date`, `avatar-date` )
- VALUES ( %d, '%s', 1, '%s', '%s', '%s', '%s', '%s', 0, 0, '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s' ) ",
+ $r = q("INSERT INTO `contact` ( `uid`, `created`, `self`, `name`, `nick`, `photo`, `thumb`, `micro`, `blocked`, `pending`, `url`, `nurl`,
+ `request`, `notify`, `poll`, `confirm`, `poco`, `name-date`, `uri-date`, `avatar-date` )
+ VALUES ( %d, '%s', 1, '%s', '%s', '%s', '%s', '%s', 0, 0, '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s', '%s' ) ",
intval($newuid),
datetime_convert(),
dbesc($username),
@@ -279,10 +279,12 @@ function register_post(&$a) {
dbesc($a->get_baseurl() . "/photo/avatar/{$newuid}.jpg"),
dbesc($a->get_baseurl() . "/photo/micro/{$newuid}.jpg"),
dbesc($a->get_baseurl() . "/profile/$nickname"),
+ dbesc(normalise_link($a->get_baseurl() . "/profile/$nickname")),
dbesc($a->get_baseurl() . "/dfrn_request/$nickname"),
dbesc($a->get_baseurl() . "/dfrn_notify/$nickname"),
dbesc($a->get_baseurl() . "/dfrn_poll/$nickname"),
dbesc($a->get_baseurl() . "/dfrn_confirm/$nickname"),
+ dbesc($a->get_baseurl() . "/poco/$nickname"),
dbesc(datetime_convert()),
dbesc(datetime_convert()),
dbesc(datetime_convert())