예제 #1
0
$this->buildBreadcrumbs($chnid);
?>
<div class="container">
	<div class="columnMain">
		<div class="tbox channelHot border">
			<?php 
$channelHot = DataSource::getContentByChannel(103, ['flag' => '64', 'limit' => 1]);
if (isset($channelHot[0])) {
    $hotContent = $channelHot[0];
    ?>
			<a href="<?php 
    echo UrlUtility::getContentUrl($hotContent);
    ?>
">
				<img src="<?php 
    echo CommonUtility::getTitlePic($hotContent);
    ?>
" style="width:380px;"></a>
			<h2><?php 
    echo UrlUtility::getContentLink($hotContent);
    ?>
</h2>
			<p style="width:260px;"><?php 
    echo TStringHelper::subStr($hotContent['summary'], 100);
    ?>
				<a href="<?php 
    echo UrlUtility::getContentUrl($hotContent);
    ?>
">[详细]</a></p>		
			<?php 
}
예제 #2
0
use common\includes\UrlUtility;
use common\includes\CommonUtility;
use components\helpers\TStringHelper;
?>
<li>
<h4><a href="<?php 
echo $row['url'];
?>
"><?php 
echo TStringHelper::subStr($row['title'], $length);
?>
</a></h4>
<a href="<?php 
echo $row['url'];
?>
">
	<img src="<?php 
echo CommonUtility::getTitlePic($row);
?>
" border="0" alt="<?php 
echo $row['title'];
?>
" />
</a>
<p><?php 
echo $row['summary'];
?>
</p>
</li>