Only show foreign items if the profile of the user isn't hidden. Show the user's theme - not the theme of the viewed profile.
This commit is contained in:
parent
4ad2bbddc7
commit
4bdd905b3e
2
boot.php
2
boot.php
|
@ -1414,7 +1414,9 @@ if(! function_exists('profile_load')) {
|
||||||
|
|
||||||
$a->page['title'] = $a->profile['name'] . " @ " . $a->config['sitename'];
|
$a->page['title'] = $a->profile['name'] . " @ " . $a->config['sitename'];
|
||||||
|
|
||||||
|
if (!$profiledata)
|
||||||
$_SESSION['theme'] = $a->profile['theme'];
|
$_SESSION['theme'] = $a->profile['theme'];
|
||||||
|
|
||||||
$_SESSION['mobile-theme'] = $a->profile['mobile-theme'];
|
$_SESSION['mobile-theme'] = $a->profile['mobile-theme'];
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -33,7 +33,7 @@ function display_init(&$a) {
|
||||||
WHERE `item`.`visible` = 1 AND `item`.`deleted` = 0 and `item`.`moderated` = 0
|
WHERE `item`.`visible` = 1 AND `item`.`deleted` = 0 and `item`.`moderated` = 0
|
||||||
AND `item`.`allow_cid` = '' AND `item`.`allow_gid` = ''
|
AND `item`.`allow_cid` = '' AND `item`.`allow_gid` = ''
|
||||||
AND `item`.`deny_cid` = '' AND `item`.`deny_gid` = ''
|
AND `item`.`deny_cid` = '' AND `item`.`deny_gid` = ''
|
||||||
AND `item`.`private` = 0
|
AND `item`.`private` = 0 AND NOT `user`.`hidewall`
|
||||||
AND `item`.`guid` = '%s'", $a->argv[1]);
|
AND `item`.`guid` = '%s'", $a->argv[1]);
|
||||||
// AND `item`.`private` = 0 AND `item`.`wall` = 1
|
// AND `item`.`private` = 0 AND `item`.`wall` = 1
|
||||||
if (count($r)) {
|
if (count($r)) {
|
||||||
|
@ -65,6 +65,10 @@ function display_init(&$a) {
|
||||||
} else
|
} else
|
||||||
$profiledata = array();
|
$profiledata = array();
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
$a->error = 404;
|
||||||
|
notice( t('Item not found.') . EOL);
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -220,7 +224,7 @@ function display_content(&$a, $update = 0) {
|
||||||
WHERE `item`.`visible` = 1 AND `item`.`deleted` = 0 and `item`.`moderated` = 0
|
WHERE `item`.`visible` = 1 AND `item`.`deleted` = 0 and `item`.`moderated` = 0
|
||||||
AND `item`.`allow_cid` = '' AND `item`.`allow_gid` = ''
|
AND `item`.`allow_cid` = '' AND `item`.`allow_gid` = ''
|
||||||
AND `item`.`deny_cid` = '' AND `item`.`deny_gid` = ''
|
AND `item`.`deny_cid` = '' AND `item`.`deny_gid` = ''
|
||||||
AND `item`.`private` = 0
|
AND `item`.`private` = 0 AND NOT `user`.`hidewall`
|
||||||
AND `item`.`guid` = '%s'", $a->argv[1]);
|
AND `item`.`guid` = '%s'", $a->argv[1]);
|
||||||
// AND `item`.`private` = 0 AND `item`.`wall` = 1
|
// AND `item`.`private` = 0 AND `item`.`wall` = 1
|
||||||
if (count($r)) {
|
if (count($r)) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user