Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有两个字段,开始日期和结束日期。我想在添加新内容时隐藏结束日期,并希望开始日期在编辑时不可编辑并显示结束日期以进行编辑。我如何在 drupal 6 节点模块中做到这一点?
使用表单更改,您可以使用 url 参数来查看它是添加还是编辑表单如果添加表单说 $form['start_date']['#access']=false; 并在编辑表单中跳过相同的内容
$form['start_date']['#access']=false;