aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--README6
-rw-r--r--addon/facebook/facebook.php21
-rw-r--r--boot.php3
-rw-r--r--images/smiley-heart.gifbin0 -> 592 bytes
-rw-r--r--include/acl_selectors.php2
-rw-r--r--mod/dfrn_notify.php3
-rw-r--r--view/comment_item.tpl10
7 files changed, 19 insertions, 26 deletions
diff --git a/README b/README
index e5c5e02d6..36bd01792 100644
--- a/README
+++ b/README
@@ -40,10 +40,8 @@ interaction you've grown to love, *and* was free to use, *and* was open source,
*and* where your privacy is always under your control?
And what if this social network could scale to encompass the entire
-internet, and *not* require a central organisation to provide servers (in
-exchange for selling your private information; and everything else they can
-find out about you - from logging all of your online activities and
-conversations)?
+internet, and *not* require a central organisation to provide servers?
+(In exchange for peddling your private information behind your back.)
Look no further.
diff --git a/addon/facebook/facebook.php b/addon/facebook/facebook.php
index 93e7962c3..119ee2f3e 100644
--- a/addon/facebook/facebook.php
+++ b/addon/facebook/facebook.php
@@ -123,15 +123,12 @@ function facebook_content(&$a) {
function facebook_install() {
register_hook('post_local_end', 'addon/facebook/facebook.php', 'facebook_post_hook');
register_hook('jot_networks', 'addon/facebook/facebook.php', 'facebook_jot_nets');
- register_hook('post_local_start','addon/facebook/facebook.php', 'facebook_post_local');
-
}
function facebook_uninstall() {
unregister_hook('post_local_end', 'addon/facebook/facebook.php', 'facebook_post_hook');
unregister_hook('jot_networks', 'addon/facebook/facebook.php', 'facebook_jot_nets');
- unregister_hook('post_local_start','addon/facebook/facebook.php', 'facebook_post_local');
}
@@ -148,16 +145,6 @@ function facebook_jot_nets(&$a,&$b) {
}
}
-function facebook_post_local(&$a,&$b) {
- if(! local_user())
- return;
-
- if((x($b,'facebook_enable')) && (intval($b['facebook_enable'])))
- set_pconfig(local_user(),'facebook','enable','1');
- else
- del_pconfig(local_user(),'facebook','enable');
-}
-
function facebook_post_hook(&$a,&$b) {
@@ -175,17 +162,21 @@ function facebook_post_hook(&$a,&$b) {
if($appid && $secret) {
+ logger('facebook: have appid+secret');
+
$fb_post = intval(get_pconfig(local_user(),'facebook','post'));
- $fb_enable = intval(get_pconfig(local_user(),'facebook','enable'));
+ $fb_enable = (($fb_post && x($_POST,'facebook_enable')) ? intval($_POST['facebook_enable']) : 0);
$fb_token = get_pconfig(local_user(),'facebook','access_token');
+ logger('facebook: $fb_post: ' . $fb_post . ' $fb_enable: ' . $fb_enable . ' $fb_token: ' . $fb_token,LOGGER_DEBUG);
if($fb_post && $fb_token && $fb_enable) {
+ logger('facebook: able to post');
require_once('library/facebook.php');
require_once('include/bbcode.php');
$msg = $b['body'];
- logger('Facebook post2: msg=' . $msg, LOGGER_DATA);
+ logger('Facebook post: original msg=' . $msg, LOGGER_DATA);
// make links readable before we strip the code
diff --git a/boot.php b/boot.php
index 2cbc48cde..6a1d3a04b 100644
--- a/boot.php
+++ b/boot.php
@@ -1978,8 +1978,9 @@ function smilies($s) {
$a = get_app();
return str_replace(
- array( ':-)', ';-)', ':-(', ':(', ':-P', ':-"', ':-x', ':-X', ':-D', '8-|', '8-O'),
+ array( '<3', ':-)', ';-)', ':-(', ':(', ':-P', ':-"', ':-x', ':-X', ':-D', '8-|', '8-O'),
array(
+ '<img src="' . $a->get_baseurl() . '/images/smiley-heart.gif" alt="<3" />',
'<img src="' . $a->get_baseurl() . '/images/smiley-smile.gif" alt=":-)" />',
'<img src="' . $a->get_baseurl() . '/images/smiley-wink.gif" alt=";-)" />',
'<img src="' . $a->get_baseurl() . '/images/smiley-frown.gif" alt=":-(" />',
diff --git a/images/smiley-heart.gif b/images/smiley-heart.gif
new file mode 100644
index 000000000..21c0c6530
--- /dev/null
+++ b/images/smiley-heart.gif
Binary files differ
diff --git a/include/acl_selectors.php b/include/acl_selectors.php
index 953243a43..94f51a9ff 100644
--- a/include/acl_selectors.php
+++ b/include/acl_selectors.php
@@ -44,6 +44,8 @@ function group_select($selname,$selclass,$preselected = false,$size = 4) {
function contact_select($selname, $selclass, $preselected = false, $size = 4, $privmail = false, $celeb = false, $privatenet = false) {
+ $a = get_app();
+
$o = '';
// When used for private messages, we limit correspondence to mutual friends and the selector
diff --git a/mod/dfrn_notify.php b/mod/dfrn_notify.php
index dffbb5974..755d674c1 100644
--- a/mod/dfrn_notify.php
+++ b/mod/dfrn_notify.php
@@ -391,8 +391,9 @@ function dfrn_notify_post(&$a) {
intval($importer['importer_uid'])
);
if(count($myconv)) {
+ $importer_url = $a->get_baseurl() . '/profile/' . $importer['nickname'];
foreach($myconv as $conv) {
- if(! link_compare($conv['author-link'],$importer['url']))
+ if(! link_compare($conv['author-link'],$importer_url))
continue;
require_once('bbcode.php');
$from = stripslashes($datarray['author-name']);
diff --git a/view/comment_item.tpl b/view/comment_item.tpl
index 068cf0731..885d735ed 100644
--- a/view/comment_item.tpl
+++ b/view/comment_item.tpl
@@ -1,9 +1,9 @@
<div class="comment-$wwedit-wrapper" id="comment-edit-wrapper-$id" style="display: block;">
- <form class="comment-edit-form" id="comment-edit-form-$id" method="post" onsubmit="post_comment($id); return false;">
- <input id="f-type-$id" type="hidden" name="type" value="$type" />
- <input id="f-profile-uid-$id" type="hidden" name="profile_uid" value="$profile_uid" />
- <input id="f-parent-$id" type="hidden" name="parent" value="$parent" />
- <input id="f-return-path-$id" type="hidden" name="return" value="$return_path" />
+ <form class="comment-edit-form" id="comment-edit-form-$id" action="item" method="post" onsubmit="post_comment($id); return false;">
+ <input type="hidden" name="type" value="$type" />
+ <input type="hidden" name="profile_uid" value="$profile_uid" />
+ <input type="hidden" name="parent" value="$parent" />
+ <input type="hidden" name="return" value="$return_path" />
<div class="comment-edit-photo" id="comment-edit-photo-$id" >
<a class="comment-edit-photo-link" href="$mylink" title="$mytitle"><img class="my-comment-photo" src="$myphoto" alt="$mytitle" title="$mytitle" /></a>