当前位置: 首页>>代码示例>>PHP>>正文


PHP Lib::colorizeHTML方法代码示例

本文整理汇总了PHP中Lib::colorizeHTML方法的典型用法代码示例。如果您正苦于以下问题:PHP Lib::colorizeHTML方法的具体用法?PHP Lib::colorizeHTML怎么用?PHP Lib::colorizeHTML使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Lib的用法示例。


在下文中一共展示了Lib::colorizeHTML方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: date

}
$message = '
		<div style="    border: 1px solid silver;    border-radius: 8px 8px 8px 8px;    margin: 8px;    overflow: auto;">
			<div class="fecha" title="Hora: ' . date('H', $date) . ':' . date('i', $date) . '" style="    color: gray;    float: left;    font-weight: bold;    text-align: center;    width: 48px;">
				<div class="dia" style="font-size: 28px;">' . date('d', $date) . '</div>
				<div class="mes" style="">' . date('M', $date) . '</div>
				<div class="ano" style="font-size: 10px;">' . date('Y', $date) . '</div>
			</div>
			<div class="botones margen" style="clear: right; float: right; padding: 16px;">
				<a href="http://' . $_SERVER['HTTP_HOST'] . Config::get('FORUM_URL') . '?pregunta=' . $pregunta->getQuestion()->getId() . '#q' . $pregunta->getId() . '" class="shadow-button shadow-button-blue" style="    border: 1px solid silver;    border-radius: 3px 3px 3px 3px;    color: white;    cursor: pointer;    font-size: 12px;    font-weight: bold;    margin: 0;    padding: 7px;    text-transform: uppercase; background-color: #4D90FE; text-decoration:none;">Responder</a>
			</div>
			<div style="margin-left: 48px; padding: 16px;">
				<div class="pie" style="">
					' . $autor_txt . '
				</div>
				' . Lib::colorizeHTML($pregunta->getText()) . '
			</div>
		</div>
		<br>
		<br>
		Enlace para responder <a href="http://' . $_SERVER['HTTP_HOST'] . Config::get('FORUM_URL') . '?pregunta=' . $pregunta->getQuestion()->getId() . '#q' . $pregunta->getId() . '">http://' . $_SERVER['HTTP_HOST'] . Config::get('FORUM_URL') . '?pregunta=' . $pregunta->getQuestion()->getId() . '#q' . $pregunta->getId() . '</a>
		';
$headers = "MIME-Version: 1.0\n";
$headers .= 'Content-Type: text/html; charset=UTF-8' . "\n";
$headers .= 'Message-ID: <' . md5($pregunta->getQuestion()->getId()) . '@ibentus.treeweb.es>' . "\n";
$headers .= "Reply-To: " . $login . "\n";
$headers .= "From: " . Config::get('FORUM_SENDER_EMAIL') . "\n";
$headers .= "X-Priority: 1 (Higuest)\n";
$headers .= "X-MSMail-Priority: High\n";
$headers .= "Importance: High\n";
$usuarios = SystemUser::SELECT();
开发者ID:fulldump,项目名称:8,代码行数:31,代码来源:make_question.php

示例2: drawAnswers

 public function drawAnswers()
 {
     $classname = 'foro-elem';
     if (Session::isLoggedIn() && $this->getUser()->getId() == Session::getUser()->getId()) {
         $classname .= ' foro-elem-user';
     }
     echo '<div class="' . $classname . '" id="q' . $this->getId() . '">';
     $date = $this->getTimestamp();
     echo '<div class="fecha" title="Hora: ' . date('H', $date) . ':' . date('i', $date) . '">';
     echo '<div class="dia">' . date('d', $date) . '</div>';
     echo '<div class="mes">' . date('M', $date) . '</div>';
     echo '<div class="ano">' . date('Y', $date) . '</div>';
     echo '</div>';
     echo '<div class="botones margen">';
     echo '<button id="answer-button1-' . $this->getId() . '" class="shadow-button shadow-button-blue" onclick="botonResponderClick(\'' . $this->getId() . '\'); this.style.display=\'none\'">Responder</button>';
     echo '</div>';
     echo '<div class="margen texto">';
     echo '<div class="pie">';
     $autor = $this->getUser();
     if ($autor != null) {
         echo '<div class="autor">por <em>' . htmlentities($this->getUser()->getName(), ENT_COMPAT, 'utf-8') . '</em></div>';
     }
     // TODO: Contar y escribir comentarios:
     echo '<div class="comentarios">' . $this->getNumResponses() . ' respuestas</div>';
     echo '</div>';
     echo Lib::colorizeHTML($this->getText());
     echo '</div>';
     echo '<div id="answer' . $this->getId() . '" class="margen" style="background-color:silver; display:none;">fasdfasfdffdfdfdfafsd';
     echo '</div>';
     echo '</div>';
     echo '<div id="hijos' . $this->getId() . '" class="foro-hijos">';
     $hijos = $this->getResponses();
     foreach ($hijos as $h) {
         $h->drawAnswers();
     }
     echo '</div>';
 }
开发者ID:fulldump,项目名称:8,代码行数:37,代码来源:extended.class.php


注:本文中的Lib::colorizeHTML方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。