一些 cck 字段未转换为 HTML
我也在 drupal.stackexchange 上问了这个问题,但回复很穷。
我的问题发生在我自定义的基于 Zen 的主题中,我在其中创建了自定义节点类型“事件”。我将 print_r($node) 放在我的 node-events.tpl.php 中,它提供了所有 ckk 字段,包括那些未转换为 HTML(即未显示)的字段。
在库存 drupal 主题中查看此类节点时,不会发生此问题,因此所有内容都会按需要显示。这意味着我的查看权限已受到检查,并且也在管理 -> 内容类型 -> 下。 '事件' ->显示隐藏字段已关闭(设置为标准,就像我没有遇到问题时一样)
I asked this question at drupal.stackexchange as well but response is poor.
My problem happens in my custom Zen-based theme where I made a custom node type 'events'. I put print_r($node) inside of my node-events.tpl.php which gave all the ckk fields including the ones that didn't turn into HTML i.e. not displayed.
When viewing this type of node in a stock drupal theme, this problem doesn't occur so everything gets displayed as desired. This means my viewing permissions are in check and also under admin->content type-> 'events' -> display fields hidden is turned off (set to standard just the way it was when I didn't have the problem)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
清除缓存。
清除主题缓存。
我想这应该有帮助。
clear cache.
clear theme cache.
Guess this should help.
毕竟,我出于其他目的而重写了 tpl.php,而不是影响此内容类型。因此,删除站点/所有/主题/模板文件夹中的模板文件就可以了。
After all, it was a tpl.php I had overridden for another purpose than this content type that influenced this. So getting rid of that template file in my sites/all/themes/templates folder did the trick.