smarty - 如何使用 smarty 显示特殊字符,例如 '%'?
问题描述
我正在设计一个 prestashop 主题,我遇到了 smarty 模板引擎的问题。
我用特殊字符 '%' 写了一个文本,但没有显示任何内容。
<p>
{l s='Save hundreds of hours of manual work, be more productive and impress your audience with visually appealing slides that are 100% editable.' d='Shop.Theme.Global'}
</p>
解决方案
thk Melvita,但我放了 %%。<l s='Save hundreds of hours of manual work, be more productive and impress your audience with visually appealing slides that are 100%% editable.'>
它有效
推荐阅读
- sql - 左侧连接表的快速刷新需要这么多次
- apache - Apache ReverseProxy Netscaler Gateway 中止请求,因为 Set-Cookie 中的字符无效
- c++ - 如何在 C/C++ 中正确实现链接列表而不会导致程序崩溃
- ajax - 带有ajax分页的Django Rest框架,如何在模板中切换数据?
- php - 无法在一行中获取一个 ID 和另一个同名 ID?
- android - FFMPEG 幻灯片 - 仅显示第一帧
- django - django 注册用户为超级用户
- xml - xpath 请求选择恰好出现两次的元素
- java - 创建了一个包含 Flyway 迁移的 docker 镜像
- javascript - 表单输入返回为 0