<?php
// Only in content_type = 'story' is visible
$content_type = '';
if(!isset($GLOBALS['content_type'])){
if(arg(0) == 'node'){
$sql = sprintf('SELECT type FROM {node} WHERE nid = %d', arg(1));
$db_result = db_query($sql);
$resultArr = db_fetch_array($db_result);
$content_type = $resultArr['type'];
$GLOBALS['content_type'] = $content_type;
} else {
return false;
}
} else {
$content_type = $GLOBALS['content_type'];
}
if($content_type == 'story')
return true;
else
return false;
?>