From 3c04676a32b048677813c1d8a4c525963a7b2f01 Mon Sep 17 00:00:00 2001 From: friendica Date: Sun, 7 Oct 2012 21:44:11 -0700 Subject: get posts to show up --- mod/network.php | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'mod') diff --git a/mod/network.php b/mod/network.php index 3f06ccb3d..ad3d43102 100644 --- a/mod/network.php +++ b/mod/network.php @@ -602,7 +602,7 @@ function network_content(&$a, $update = 0, $load = false) { if($nouveau && $load) { // "New Item View" - show all items unthreaded in reverse created date order - +/* $items = q("SELECT `item`.*, `item`.`id` AS `item_id`, o.xchan_name as oname, o.xchan_photo as ophoto, o.xchan_profile as ourl, a.xchan_name as aname, a.xchan_photo as aphoto, a.xchan_profile as aurl, @@ -614,7 +614,7 @@ function network_content(&$a, $update = 0, $load = false) { ORDER BY `item`.`received` DESC $pager_sql ", intval($_SESSION['uid']) ); - +*/ require_once('include/items.php'); $items = fetch_post_tags($items); @@ -632,7 +632,7 @@ function network_content(&$a, $update = 0, $load = false) { // Fetch a page full of parent items for this page if($update && (! $load)) { - $r = q("SELECT `parent` AS `item_id`, `contact`.`uid` AS `contact_uid` +/* $r = q("SELECT `parent` AS `item_id`, `contact`.`uid` AS `contact_uid` FROM `item` LEFT JOIN `contact` ON `contact`.`id` = `item`.`contact-id` WHERE `item`.`uid` = %d AND `item`.`visible` = 1 AND (`item`.`deleted` = 0 OR item.verb = '" . ACTIVITY_LIKE ."' OR item.verb = '" . ACTIVITY_DISLIKE . "') @@ -641,7 +641,7 @@ function network_content(&$a, $update = 0, $load = false) { $sql_extra3 $sql_extra $sql_nets ", intval(local_user()) ); - } +*/ } else { $r = q("SELECT `item`.`id` AS `item_id` @@ -660,11 +660,7 @@ function network_content(&$a, $update = 0, $load = false) { $parents_str = ids_to_querystr($r,'item_id'); - $items = q("SELECT `item`.*, `item`.`id` AS `item_id`, - o.xchan_name as oname, o.xchan_photo as ophoto, o.xchan_profile as ourl, - a.xchan_name as aname, a.xchan_photo as aphoto, a.xchan_profile as aurl, - FROM `item` left join xchan as o on xchan_hash = owner_xchan left join xchan as a - on xchan_hash = author_xchan + $items = q("SELECT `item`.*, `item`.`id` AS `item_id` FROM `item` WHERE `item`.`uid` = %d AND `item`.`item_restrict` = 0 AND `item`.`parent` IN ( %s ) $sql_extra ", @@ -672,10 +668,14 @@ function network_content(&$a, $update = 0, $load = false) { dbesc($parents_str) ); + + xchan_query($items); + $items = fetch_post_tags($items); $items = conv_sort($items,$ordering); +logger('items: ' . print_r($items,true)); } else { $items = array(); -- cgit v1.2.3