]> git.mxchange.org Git - friendica.git/blobdiff - mod/ping.php
Merge pull request #3769 from annando/show-forum-posts
[friendica.git] / mod / ping.php
index 5a5bdcd5890b9be772ddfdb14b00e1402d430431..59fa52121411429ae6acff8bb90f8b9743d4badd 100644 (file)
@@ -118,7 +118,7 @@ function ping_init(App $a)
 
                $notifs = ping_get_notifications(local_user());
 
-               $items_unseen = qu("SELECT `item`.`id`, `item`.`parent`, `item`.`verb`, `item`.`wall`, `item`.`author-name`,
+               $items_unseen = q("SELECT `item`.`id`, `item`.`parent`, `item`.`verb`, `item`.`wall`, `item`.`author-name`,
                                `item`.`contact-id`, `item`.`author-link`, `item`.`author-avatar`, `item`.`created`, `item`.`object`,
                                `pitem`.`author-name` AS `pname`, `pitem`.`author-link` AS `plink`
                                FROM `item` INNER JOIN `item` AS `pitem` ON  `pitem`.`id` = `item`.`parent`
@@ -167,13 +167,13 @@ function ping_init(App $a)
                        }
                }
 
-               $intros1 = qu("SELECT  `intro`.`id`, `intro`.`datetime`,
+               $intros1 = q("SELECT  `intro`.`id`, `intro`.`datetime`,
                        `fcontact`.`name`, `fcontact`.`url`, `fcontact`.`photo`
                        FROM `intro` LEFT JOIN `fcontact` ON `intro`.`fid` = `fcontact`.`id`
                        WHERE `intro`.`uid` = %d  AND `intro`.`blocked` = 0 AND `intro`.`ignore` = 0 AND `intro`.`fid` != 0",
                        intval(local_user())
                );
-               $intros2 = qu("SELECT `intro`.`id`, `intro`.`datetime`,
+               $intros2 = q("SELECT `intro`.`id`, `intro`.`datetime`,
                        `contact`.`name`, `contact`.`url`, `contact`.`photo`
                        FROM `intro` LEFT JOIN `contact` ON `intro`.`contact-id` = `contact`.`id`
                        WHERE `intro`.`uid` = %d  AND `intro`.`blocked` = 0 AND `intro`.`ignore` = 0 AND `intro`.`contact-id` != 0",
@@ -184,7 +184,7 @@ function ping_init(App $a)
                $intros = $intros1 + $intros2;
 
                $myurl = System::baseUrl() . '/profile/' . $a->user['nickname'] ;
-               $mails = qu("SELECT `id`, `from-name`, `from-url`, `from-photo`, `created` FROM `mail`
+               $mails = q("SELECT `id`, `from-name`, `from-url`, `from-photo`, `created` FROM `mail`
                        WHERE `uid` = %d AND `seen` = 0 AND `from-url` != '%s' ",
                        intval(local_user()),
                        dbesc($myurl)
@@ -192,7 +192,7 @@ function ping_init(App $a)
                $mail_count = count($mails);
 
                if ($a->config['register_policy'] == REGISTER_APPROVE && is_site_admin()){
-                       $regs = qu("SELECT `contact`.`name`, `contact`.`url`, `contact`.`micro`, `register`.`created`, COUNT(*) AS `total`
+                       $regs = q("SELECT `contact`.`name`, `contact`.`url`, `contact`.`micro`, `register`.`created`, COUNT(*) AS `total`
                                FROM `contact` RIGHT JOIN `register` ON `register`.`uid` = `contact`.`uid`
                                WHERE `contact`.`self` = 1");
 
@@ -204,7 +204,7 @@ function ping_init(App $a)
                $cachekey = "ping_init:".local_user();
                $ev = Cache::get($cachekey);
                if (is_null($ev)) {
-                       $ev = qu("SELECT type, start, adjust FROM `event`
+                       $ev = q("SELECT type, start, adjust FROM `event`
                                WHERE `event`.`uid` = %d AND `start` < '%s' AND `finish` > '%s' and `ignore` = 0
                                ORDER BY `start` ASC ",
                                intval(local_user()),
@@ -424,7 +424,7 @@ function ping_get_notifications($uid)
        $a = get_app();
 
        do {
-               $r = qu("SELECT `notify`.*, `item`.`visible`, `item`.`spam`, `item`.`deleted`
+               $r = q("SELECT `notify`.*, `item`.`visible`, `item`.`spam`, `item`.`deleted`
                        FROM `notify` LEFT JOIN `item` ON `item`.`id` = `notify`.`iid`
                        WHERE `notify`.`uid` = %d AND `notify`.`msg` != ''
                        AND NOT (`notify`.`type` IN (%d, %d))