You shoudln't use a text variable like an array.

This commit is contained in:
Michael 2017-03-18 23:32:59 +00:00
parent 909e1e055f
commit fb5f1f61fc

View File

@ -903,10 +903,10 @@ function contact_block() {
intval($shown)
);
if (dbm::is_result($r)) {
$contacts = "";
foreach ($r AS $contact)
$contacts = array();
foreach ($r AS $contact) {
$contacts[] = $contact["id"];
}
$r = q("SELECT `id`, `uid`, `addr`, `url`, `name`, `thumb`, `network` FROM `contact` WHERE `id` IN (%s)",
dbesc(implode(",", $contacts)));