Closed (fixed)
Project:
Zen
Version:
6.x-1.0-beta2
Component:
Code
Priority:
Critical
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
4 Jun 2008 at 14:35 UTC
Updated:
12 Sep 2008 at 10:07 UTC
Hi,
Normally, with drupal 6, I should be able to theme a node_type creation form by creating a node_type-node-form.tpl.php file.
It works for a global node-form.tpl.php, but don't work with story-node-form.tpl.php for example.
It is a knows bug in the zen beta that explain this problem ?
regards,
zmove
Comments
Comment #1
zmove commentedHi,
I have news about my problem, it seems that ou have to declare the function in hook_theme before beeing able to use it. see : http://drupalbin.com/1908
The problem is that zen subtheme already have a zen_theme() function, so I don't know how to do that... I would modify the template.php in the zen master theme, but I would prefer not hacking zen core...
How can I do that please ?
Comment #2
johnalbinHmm.. Ok. You can still modify the _theme() function in you subtheme. This might work:
Try that and let me know if it works. Then I can modify the STARTERKIT to make this easier for people in the future.
Comment #3
zmove commentedHi,
I tried to put your code like that :
It bring me an error when I want to edit my node of type : recipe
Any ideas how to fix it ?
Comment #4
johnalbinRelated to this issue, see: #272655: Make STARTERKIT_theme easier to extend
Comment #5
niklp commentedSo is this fixed...?
Comment #6
zmove commentedForget it, I miss the function STARTERKIT_page_node_form() { … }
So it mean that it's not possible to theme a form in a .tpl.php file ? you have to define it in the function above ?
Comment #7
johnalbinzmove
Uh, no, you can't define functions in .tpl.php files. They should go in your template.php.
This issue doesn't sound like a Zen-related bug. And (if you couldn't already tell from how long it took for you to get a response in this issue queue), I think the best place to get support for this would be in IRC. As I don't know much about form theming.