Source

Uva Searchengines / protected / views / search / _view.php

Full commit
	<?php
	$model = Article::model()->cache(3600)->findByPk($data['id']);
	echo $model->id;
	echo ', ';
	echo Yii::app()->dateFormatter->formatDateTime($model->date, 'medium', '');
	echo '<h2>' . CHtml::link($query->highlightMatches($model->title), array('article/view', 'id' => $model->id)) . '</h2>';
	echo '<strong>Score: ' . $data['score'] . '</strong>';
// fix for strange zend highlight bug
	echo '<p>' . $query->highlightMatches(utf8_decode(utf8_decode($model->body))) . '</p>';
	?>
	<br>