【问题标题】:Opencart $description adding inline stylingOpencart $description 添加内联样式
【发布时间】:2012-10-24 22:42:25
【问题描述】:

我正在使用 Opencart 开发一个网站。似乎在调用 $description 时添加了内联样式。

this product page 上,产品描述添加了以下内联样式:

<span style="color: rgb(51, 51, 51); font-family: Arial, Helvetica, sans-serif; 
line-height: 18px; ">

another product page 上,跨度样式为:

<span style="color: rgb(0, 0, 0); font-family: Arial, Helvetica, sans; 
font-size: 11px; line-height: 14px; text-align: justify; ">

这真的让我很困惑,因为他们都在使用 /catalog/view/theme/[theme-name]/product/product.tpl 而 php 是:

<div id="product-description"><?php echo $description; ?></div>

category page 上,$description 具有这种样式:

<span style="font-family: arial, sans-serif; font-size: small; line-height:
14.545454025268555px; ">

谁能告诉我这到底是从哪里来的?

MTIA!

【问题讨论】:

    标签: php styles opencart


    【解决方案1】:

    样式实际上来自管理面板中的编辑器。它使用 TinyMCE(模仿富文本编辑器的 JavaScript 编辑器),这就是原因。如果您在编辑产品时单击描述区域中的source按钮,您可以看到和编辑此代码

    【讨论】:

    • 哦谢谢谢谢! :-) 早该检查... 刘海头
    猜你喜欢
    • 1970-01-01
    • 2013-01-23
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2018-08-15
    • 2015-11-05
    • 2019-04-11
    • 1970-01-01
    相关资源
    最近更新 更多