Beispiel #1
0
			<li class="active"><a href="#comment" data-toggle="tab">评论</a></li>
			<li><a href="#qa" data-toggle="tab">问答</a></li>
			<li><a href="#attachment" data-toggle="tab">附件</a></li>
		</ul>
		<div class="tab-content">
			<div class="tab-pane active" id="comment">
				<div class="col-lg-12 col-md-12 col-sm-12 col-xs-12 comment-input">
          <textarea class="form-control" placeholder="扯淡、吐槽、表扬、鼓励……想说啥就说啥!" id="comment-input" rows="3"></textarea>
          <button class="btn btn-info emotion" type="button"><span class="icon-smile icon-large">&nbsp;添加表情</span></button>
        	<button class="btn btn-success comment-send" type="button" id="addCommentSubmit"><span class="icon-mail-forward icon-large">&nbsp;发表评论</span></button>
        </div>
        

        <div class="col-lg-12 col-md-12 col-sm-12 col-xs-12 comment-detail">
					<?php if (CourseComment::commentList($course->id)): ?>					
						<?php $i = 1; foreach (CourseComment::commentList($course->id) as $comment): ?>
							<div class="media col-lg-12 evaluation-con">
							  <div class="media-left media-middle">
							    <a href="#">
							      <img class="media-object img-circle" src="<?php echo User::findModel($comment->user_id)->head_picture?>" alt="" width="60px">
							    </a>
							  </div>
							  <div class="media-body">
							  	<span class="evaluation-name"><?php echo User::findModel($comment->user_id)->username?></span>
							    <h5 class="media-heading evaluation-content" id="comment-content-<?php echo $i?>"><?php echo $comment->content?></h5>
							    <?php if ($comment->course_id == $comment->root_id): ?>
							    	<span class="evaluation-time">时间:<?php echo Common::getAwayTime($comment->comment_time)?></span>
									<?php else: ?>
							    	<span class="evaluation-time">时间:<?php echo Common::getAwayTime($comment->comment_time)?>&nbsp;<a href="/resource/play?id=<?php echo Resource::getVideo($comment->course_id)->url?>">源自:<?php Course::findModel($comment->course_id)->name?></a></span>
							    <?php endif ?>
							    <span class="fa fa-thumbs-o-down comment-down" onclick="commentDown(<?php echo $comment->id?>)"><?php echo $comment->down_count?></span>