Tech
Superguide: Printers -- all you need to know
Looking to buy a printer? Our superguide rates the latest printers and shines a light into the industry.
Looking to buy a printer? Our superguide rates the latest printers and shines a light into the industry.
[?
$GLOBALS["align_ad"] = "right";
ini_set("memory_limit","200M");
//Get all stories related to Printer
library('/zdnet/livery/storyfragments/data/get_related_stories_by_keywordsolr.htm');
$whitepaper_display_limit = 34;
$categoryList = array(
'reviews' => array('name' => 'Reviews', 'channel' => 'Reviews'),
'insight' => array('name' => 'Features and Case Studies', 'channel' => array('Insight', 'Blogs')),
'news' => array('name' => 'Related News', 'channel' => 'News'),
'whitepaper' => array('name' => 'Whitepapers'),
);
foreach ($categoryList as $catLabel => $catInfo) {
?]
[?
}
?]
[?= $catInfo[name] ?]
[? unset($options); $options[rows] = 0; $options[keywords] = array("printer"); $exclude_element_ids = array(339289822); if($catLabel == "whitepaper"){ $options['fq'] = 'type:whitepaper'; $options['type'] = "whitepaper"; }else{ unset($options['type']); $options['fq'] = (is_array($catInfo['channel']) ? '+category:('.implode(' OR ', $catInfo['channel']).')' : '+category:"'.$catInfo['channel'].'"').'+type:story'; } $options['sort'] = ''; $return_arr = get_related_stories_by_keywords($options); $count = 0; foreach($return_arr as $story){ if(in_array($story->id, $exclude_element_ids)) continue; unset($url, $title, $desc); if(isset($options['type'])){ if($options['type'] == "whitepaper"){ if($count >= $whitepaper_display_limit) continue; $whitepaper_obj = new Product($story); $GLOBALS[WP_CHANNEL_NAME] = "whitepaper"; $GLOBALS[WP_DISPLAY_TID] = "2000063328"; $url = "/".$GLOBALS['WP_CHANNEL_NAME']."/0,".$GLOBALS[WP_DISPLAY_TID].",". $whitepaper_obj->product_id ."p-". $whitepaper_obj->prod_cat_id ."q,00.htm"; $title = $whitepaper_obj->product_name; $desc = str_replace(array(""), "", implode(" ", array_slice(explode(" ", $whitepaper_obj->attrib_20009355), 0, 40)))."..."; } }else{ if($story->id == 0) continue; $url = $story->url; $title = $story->title; $desc = $story->long_summary; } if ($count%4 == 2) { ?]
[? } else if ($count%4 == 0) { ?]
"="" ?="" 'left'="" :="" 'right').'"="" style="padding-bottom:10px;">More '.$catInfo[name].' » ' : '' ?]
[?= $catLabel == "whitepaper" ? '' : '' ?]
[? } ?]
[?= ($count%2 == 1) ? '
' : '' ?]
[?= $count == 3 && $catLabel != "reviews" || $count == 5 && $catLabel == "reviews" ? '[?= $title ?]
[?= $desc ?]