]> git.mxchange.org Git - friendica.git/commitdiff
Show more information when following a new contact
authorMichael Vogel <icarus@dabo.de>
Sun, 4 Oct 2015 12:41:39 +0000 (14:41 +0200)
committerMichael Vogel <icarus@dabo.de>
Sun, 4 Oct 2015 12:41:39 +0000 (14:41 +0200)
mod/follow.php [changed mode: 0755->0644]
mod/notifications.php
object/Item.php
view/templates/auto_request.tpl
view/templates/dfrn_request.tpl

old mode 100755 (executable)
new mode 100644 (file)
index dd717aa..6037078
@@ -61,6 +61,9 @@ function follow_content(&$a) {
        // Makes the connection request for friendica contacts easier
        $_SESSION["fastlane"] = $ret["url"];
 
+       $r = q("SELECT `location`, `about`, `keywords` FROM `gcontact` WHERE `nurl` = '%s'",
+               normalise_link($ret["url"]));
+
        $header = $ret["name"];
 
        if ($ret["addr"] != "")
@@ -71,25 +74,32 @@ function follow_content(&$a) {
        $o  = replace_macros($tpl,array(
                        '$header' => htmlentities($header),
                        '$photo' => $ret["photo"],
-                        '$desc' => "",
-                        '$pls_answer' => t('Please answer the following:'),
-                        '$does_know_you' => array('knowyou', sprintf(t('Does %s know you?'),$ret["name"]), false, '', array(t('No'),t('Yes'))),
-                        '$add_note' => t('Add a personal note:'),
-                        '$page_desc' => "",
-                        '$friendica' => "",
-                        '$statusnet' => "",
-                        '$diaspora' => "",
-                        '$diasnote' => "",
-                        '$your_address' => t('Your Identity Address:'),
-                        '$invite_desc' => "",
-                        '$emailnet' => "",
-                        '$submit' => t('Submit Request'),
-                        '$cancel' => t('Cancel'),
-                        '$nickname' => "",
-                        '$name' => $ret["name"],
-                        '$url' => $ret["url"],
-                        '$myaddr' => $myaddr,
-                       '$request' => $request
+                       '$desc' => "",
+                       '$pls_answer' => t('Please answer the following:'),
+                       '$does_know_you' => array('knowyou', sprintf(t('Does %s know you?'),$ret["name"]), false, '', array(t('No'),t('Yes'))),
+                       '$add_note' => t('Add a personal note:'),
+                       '$page_desc' => "",
+                       '$friendica' => "",
+                       '$statusnet' => "",
+                       '$diaspora' => "",
+                       '$diasnote' => "",
+                       '$your_address' => t('Your Identity Address:'),
+                       '$invite_desc' => "",
+                       '$emailnet' => "",
+                       '$submit' => t('Submit Request'),
+                       '$cancel' => t('Cancel'),
+                       '$nickname' => "",
+                       '$name' => $ret["name"],
+                       '$url' => $ret["url"],
+                       '$url_label' => t("Profile URL"),
+                       '$myaddr' => $myaddr,
+                       '$request' => $request,
+                       '$location' => bbcode($r[0]["location"]),
+                       '$location_label' => t("Location:"),
+                       '$about' => bbcode($r[0]["about"]),
+                       '$about_label' => t("About:"),
+                       '$keywords' => bbcode($r[0]["keywords"]),
+                       '$keywords_label' => t("Tags:")
        ));
        return $o;
 }
index 44f6dd5675ffeda3610674adfd1ce86b47173837..1fc31c3eb97d81de3fa30c4a74dced2b0397f1e5 100644 (file)
@@ -216,7 +216,6 @@ function notifications_content(&$a) {
                                        '$contact_id' => $rr['contact-id'],
                                        '$photo' => ((x($rr,'photo')) ? proxy_url($rr['photo']) : "images/person-175.jpg"),
                                        '$fullname' => $rr['name'],
-                                       '$location_label' => t('Location:'),
                                        '$location' => $rr['glocation'],
                                        '$location_label' => t('Location:'),
                                        '$about' => proxy_parse_html(bbcode($rr['gabout'], false, false)),
index 8d364e6023040e8d0ed00b0ad6e31fce33a8d1cd..c7a025861f59455501a4924770f3d5bb75f1675b 100644 (file)
@@ -644,7 +644,7 @@ class Item extends BaseObject {
                if(!$this->is_toplevel() && !(get_config('system','thread_allow') && $a->theme_thread_allow)) {
                        return '';
                }
-               
+
                $comment_box = '';
                $conv = $this->get_conversation();
                $template = get_markup_template($this->get_comment_box_template());
index 56653c6550212ad565539f8ac73575200430fa60..09e6163325206bd4cb17515f35deae0e4c0da56a 100644 (file)
@@ -1,5 +1,3 @@
-
-
 <h1>{{$header}}</h1>
 
 {{if $myaddr == ""}}
 <img src="{{$photo}}" alt="" id="dfrn-request-photo">
 {{/if}}
 
+{{if $url}}<dl><dt>{{$url_label}}</dt><dd><a target="blank" href="{{$url}}">{{$url}}</a></dd></dl>{{/if}}
+{{if $location}}<dl><dt>{{$location_label}}</dt><dd>{{$location}}</dd></dl>{{/if}}
+{{if $keywords}}<dl><dt>{{$keywords_label}}</dt><dd>{{$keywords}}</dd></dl>{{/if}}
+{{if $about}}<dl><dt>{{$about_label}}</dt><dd>{{$about}}</dd></dl>{{/if}}
+
 <div id="dfrn-request-url-wrapper" >
        <label id="dfrn-url-label" for="dfrn-url" >{{$your_address}}</label>
         {{if $myaddr}}
index 6c63c5331507d486c553a64c375af03e7f545697..d376b3a5d5795e29c02794d57d787996cc0fb03f 100644 (file)
 <img src="{{$photo}}" alt="" id="dfrn-request-photo">
 {{/if}}
 
+{{if $url}}<dl><dt>{{$url_label}}</dt><dd><a target="blank" href="{{$url}}">{{$url}}</a></dd></dl>{{/if}}
+{{if $location}}<dl><dt>{{$location_label}}</dt><dd>{{$location}}</dd></dl>{{/if}}
+{{if $keywords}}<dl><dt>{{$keywords_label}}</dt><dd>{{$keywords}}</dd></dl>{{/if}}
+{{if $about}}<dl><dt>{{$about_label}}</dt><dd>{{$about}}</dd></dl>{{/if}}
+
 <div id="dfrn-request-url-wrapper" >
        <label id="dfrn-url-label" for="dfrn-url" >{{$your_address}}</label>
        {{if $myaddr}}