Umbraco CMS 在保存内容时从图像中剥离 ALT 标签

发布于 2024-08-02 23:35:34 字数 327 浏览 5 评论 0原文

Umbraco 正在采取:

<img alt="Your Title - for example Mr., Mrs., Ms."
 src="../media/21283/q16x16.gif" width="16" height="15"/>

并将其转换为

<img alt="" src="/media/21283/q16x16.gif" width="16" height="15" rel="16,15"/>

如果我在此处理后更改 alt 标签,则 alt 标签将被保存。

Umbraco is taking:

<img alt="Your Title - for example Mr., Mrs., Ms."
 src="../media/21283/q16x16.gif" width="16" height="15"/>

And turning it into

<img alt="" src="/media/21283/q16x16.gif" width="16" height="15" rel="16,15"/>

If I alter the alt tag after this processing then the alt tag is saved.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

扛起拖把扫天下 2024-08-09 23:35:34

我的猜测是这与版本 4 中 TinyMCE(所见即所得编辑器)中的“validElements”设置有关,

该设置在 /config/tinyMCEConig.config 文件中进行编辑。寻找有效元素。 3.03 也可以这样吗?

配置文件的此部分列出了每个允许的 HTML 标记及其允许的属性。
确保其中有类似的内容:

img[id|dir........border|alt=|title....... ]

My guess is this has something to do with the 'validElements' setting in TinyMCE (the wysiwyg editor)

in version 4 this is edited in the /config/tinyMCEConig.config file. Look for validElements. It could be the same in 3.03?

Each allowed HTML tag along with it's allowed attributes is listed in this section in the config file.
Ensure you have a something like this in there:

img[id|dir........border|alt=|title.......]

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文