mirror of
https://github.com/friendica/friendica
synced 2025-04-22 13:10:11 +00:00
*much* more usage of App::get_baseurl() instead of $a->get_baseurl() (coding convention applied)
Signed-off-by: Roland Häder <roland@mxchange.org>
This commit is contained in:
parent
97c507e763
commit
f8a213e23b
19 changed files with 226 additions and 196 deletions
|
@ -810,19 +810,17 @@ function dfrn_request_content(App &$a) {
|
|||
|
||||
// At first look if an address was provided
|
||||
// Otherwise take the local address
|
||||
if (x($_GET,'addr') AND ($_GET['addr'] != ""))
|
||||
if (x($_GET,'addr') AND ($_GET['addr'] != "")) {
|
||||
$myaddr = hex2bin($_GET['addr']);
|
||||
elseif (x($_GET,'address') AND ($_GET['address'] != ""))
|
||||
} elseif (x($_GET,'address') AND ($_GET['address'] != "")) {
|
||||
$myaddr = $_GET['address'];
|
||||
elseif (local_user()) {
|
||||
} elseif (local_user()) {
|
||||
if (strlen($a->path)) {
|
||||
$myaddr = App::get_baseurl() . '/profile/' . $a->user['nickname'];
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
$myaddr = $a->user['nickname'] . '@' . substr(z_root(), strpos(z_root(),'://') + 3 );
|
||||
}
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
// last, try a zrl
|
||||
$myaddr = get_my_url();
|
||||
}
|
||||
|
@ -840,8 +838,7 @@ function dfrn_request_content(App &$a) {
|
|||
|
||||
if ($a->profile['page-flags'] == PAGE_NORMAL) {
|
||||
$tpl = get_markup_template('dfrn_request.tpl');
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
$tpl = get_markup_template('auto_request.tpl');
|
||||
}
|
||||
|
||||
|
@ -850,10 +847,12 @@ function dfrn_request_content(App &$a) {
|
|||
// see if we are allowed to have NETWORK_MAIL2 contacts
|
||||
|
||||
$mail_disabled = ((function_exists('imap_open') && (! get_config('system','imap_disabled'))) ? 0 : 1);
|
||||
if(get_config('system','dfrn_only'))
|
||||
$mail_disabled = 1;
|
||||
|
||||
if(! $mail_disabled) {
|
||||
if (get_config('system','dfrn_only')) {
|
||||
$mail_disabled = 1;
|
||||
}
|
||||
|
||||
if (! $mail_disabled) {
|
||||
$r = q("SELECT * FROM `mailacct` WHERE `uid` = %d LIMIT 1",
|
||||
intval($a->profile['uid'])
|
||||
);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue