Browse Source

Show more information when following a new contact

pull/1933/head
Michael Vogel 5 years ago
parent
commit
d0ae5ce326
5 changed files with 40 additions and 23 deletions
  1. +29
    -19
      mod/follow.php
  2. +0
    -1
      mod/notifications.php
  3. +1
    -1
      object/Item.php
  4. +5
    -2
      view/templates/auto_request.tpl
  5. +5
    -0
      view/templates/dfrn_request.tpl

+ 29
- 19
mod/follow.php View File

@ -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;
}


+ 0
- 1
mod/notifications.php View 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)),


+ 1
- 1
object/Item.php View 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());


+ 5
- 2
view/templates/auto_request.tpl View File

@ -1,5 +1,3 @@
<h1>{{$header}}</h1>
{{if $myaddr == ""}}
@ -30,6 +28,11 @@
<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}}


+ 5
- 0
view/templates/dfrn_request.tpl View File

@ -27,6 +27,11 @@
<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}}


Loading…
Cancel
Save