• <i id='GFg9W'><tr id='GFg9W'><dt id='GFg9W'><q id='GFg9W'><span id='GFg9W'><b id='GFg9W'><form id='GFg9W'><ins id='GFg9W'></ins><ul id='GFg9W'></ul><sub id='GFg9W'></sub></form><legend id='GFg9W'></legend><bdo id='GFg9W'><pre id='GFg9W'><center id='GFg9W'></center></pre></bdo></b><th id='GFg9W'></th></span></q></dt></tr></i><div id='GFg9W'><tfoot id='GFg9W'></tfoot><dl id='GFg9W'><fieldset id='GFg9W'></fieldset></dl></div>
      <bdo id='GFg9W'></bdo><ul id='GFg9W'></ul>

    <tfoot id='GFg9W'></tfoot>
  • <legend id='GFg9W'><style id='GFg9W'><dir id='GFg9W'><q id='GFg9W'></q></dir></style></legend>

    1. <small id='GFg9W'></small><noframes id='GFg9W'>

      1. 更改表单的 CCK 标题

        时间:2023-06-22

        1. <legend id='lRnmf'><style id='lRnmf'><dir id='lRnmf'><q id='lRnmf'></q></dir></style></legend>

                <bdo id='lRnmf'></bdo><ul id='lRnmf'></ul>
                  <tbody id='lRnmf'></tbody>
                <tfoot id='lRnmf'></tfoot>

                  <small id='lRnmf'></small><noframes id='lRnmf'>

                1. <i id='lRnmf'><tr id='lRnmf'><dt id='lRnmf'><q id='lRnmf'><span id='lRnmf'><b id='lRnmf'><form id='lRnmf'><ins id='lRnmf'></ins><ul id='lRnmf'></ul><sub id='lRnmf'></sub></form><legend id='lRnmf'></legend><bdo id='lRnmf'><pre id='lRnmf'><center id='lRnmf'></center></pre></bdo></b><th id='lRnmf'></th></span></q></dt></tr></i><div id='lRnmf'><tfoot id='lRnmf'></tfoot><dl id='lRnmf'><fieldset id='lRnmf'></fieldset></dl></div>
                2. 本文介绍了更改表单的 CCK 标题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  默认情况下,CCK 表单创建具有表单的标题

                  By default a CCK form creation has a title of the form

                   Create [Your Content Type Name Here]
                  

                  我想把我的改成

                   Register for Such and Such
                  

                  有人建议我可以使用字符串覆盖,但我找不到要替换的字符串.我也尝试过为 form_alter 编写代码,但似乎无法弄清楚如何更改标题".

                  It was suggested that I could use string-override, but I can't find the string to replace. I've also tried writing code to form_alter, but can't seem to figure out how to get the "title" to change.

                  想法?

                  推荐答案

                  有两种可能,一种是使用主题布局,另一种是设置页面模板中使用的$title变量.您可以使用如 lazy 建议的预处理函数来完成此操作.

                  There are two possibilities, either you can use the theming laying and set $title variable used in the page templage. You can do this with a preprocess function like lazy suggests.

                  我更喜欢的其他选项是使用 drupal_set_title(),这需要放在一个模块中.我没有试过这个,但我认为你可以在你的 hook_form_alter() 实现中使用它.这样您就可以轻松控制更改哪些标题.

                  The other options which I prefer would be to use the drupal_set_title(), this would need to go in a module. I haven't tried this, but I would think that you could use this in your hook_form_alter() implementation. That way you could control which titles get changed pretty easily.

                  这篇关于更改表单的 CCK 标题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  上一篇:Drupal 8:如何自定义表单小部件以显示实体字段值而不是实体标题? 下一篇:如果管理员或用户具有特定角色,则 Drupal 条件 PHP

                  相关文章

                  <i id='GiBJ3'><tr id='GiBJ3'><dt id='GiBJ3'><q id='GiBJ3'><span id='GiBJ3'><b id='GiBJ3'><form id='GiBJ3'><ins id='GiBJ3'></ins><ul id='GiBJ3'></ul><sub id='GiBJ3'></sub></form><legend id='GiBJ3'></legend><bdo id='GiBJ3'><pre id='GiBJ3'><center id='GiBJ3'></center></pre></bdo></b><th id='GiBJ3'></th></span></q></dt></tr></i><div id='GiBJ3'><tfoot id='GiBJ3'></tfoot><dl id='GiBJ3'><fieldset id='GiBJ3'></fieldset></dl></div>
                    <legend id='GiBJ3'><style id='GiBJ3'><dir id='GiBJ3'><q id='GiBJ3'></q></dir></style></legend>

                    1. <small id='GiBJ3'></small><noframes id='GiBJ3'>

                    2. <tfoot id='GiBJ3'></tfoot>
                        <bdo id='GiBJ3'></bdo><ul id='GiBJ3'></ul>