0
我在保存到会话闪存变量的消息中的html标记有问题。 我的下一个字符串:HTML字面打印
const SAVE_SUCCESS_MSG = "El responsable <strong>%name%</strong> fue guardado correctamente.";
我使用str_replace
值替换“%名称%”:
$replaced = str_replace('%name%', $tutor->__toString(), self::SAVE_SUCCESS_MSG);
值正确更换,但浏览器显示的标签字面上。
我打印带有嫩枝消息:
{% if app.session.flashbag.has('status') %}
<div class="alert alert-{{ app.session.flashbag.get('status')[0] }}">
<button type="button" class="close" data-dismiss="alert">×</button>
{{ app.session.flashbag.get('message')[0] }}
</div>
{% endif %}
任何想法?
浏览器呈现“Foo”。 – ramiromd
你在哪里/如何回应它? – rmobis