With the Vertical Tabs module enabled, I get warning message when adding a content type.
See attached screenshot of the warning message.

The message does not display when the Vertical Tabs module is disabled.

CommentFileSizeAuthor
#10 361838-1.patch376 bytesles lim
Vertical Tabs Error.png12.76 KBarlinsandbulte

Comments

philsward’s picture

I too am getting the same error.

I have a sandbox where I went ahead and created a new content type. While it threw up the same error after saving the new content type, It appears that everything is working fine. When I went in to edit the new content type, the error went away and I was able to select the fields I wanted to use for vertical tabs.

joshmiller’s picture

I did as well. Below is the error message for Google:

warning: call_user_func_array() [function.call-user-func-array]: First argument is expected to be a valid callback, '_node_form'

Also found this while researching the problem: "You need to include node.pages.inc before you can call drupal_get_form($type ...); as the form builder (node_form) and a lot of other important node form functions are in that file." From: http://drupal.org/node/322163#comment-1062731

So, I believe the "Create Content Type" must handle their form slightly differently...

Sorry I couldn't include a patch, hopefully the information above will help someone deal with it directly.

~ eccl

jannalexx’s picture

same error

rogerpfaff’s picture

I think the error is based on the fact that there is no fieldset on content type creation time. There should be a check if it is a new content type we create or an existing we edit.

youkho’s picture

Experienced the same error when on content types creation so i disabled Vertical Tabs untill this issue is solved

imp7’s picture

I also receive this error with vertical tabs enabled in same versions.

dnewkerk’s picture

Same error for me. If I get a chance soon I will try the current dev version to see if it's fixed now (or any feedback from the maintainer would be welcome).

les lim’s picture

Version: 6.x-1.0-beta1 » 6.x-1.x-dev

yes, it's still happening in the current 2009-Jan-27 dev version. Verifiied on a clean local install of 6.9 using Garland, with the color module turned off to prevent #355938: Can't install - color module dependancy and an undefined func.

les lim’s picture

Title: Warning message on CCK Add Content Type page » Warning message on Add Content Type page
Assigned: Unassigned » les lim

Also, this seems to happen regardless of CCK being enabled.

les lim’s picture

Status: Needs review » Active
StatusFileSize
new376 bytes

The function that looks for available fieldsets requires the node type to be passed to it. This patch prevents that function from being called if there's no specified node type (i.e., when you're adding a new content type). That should solve the warning message.

One reason this might not be the ideal solution is that if you are intending to add more vertical tabs once you've added the content type, it may not be obvious that you have to go back and re-edit the content type after setting up your fieldsets. Any thoughts?

les lim’s picture

Status: Active » Needs review
domesticat’s picture

Status: Active » Needs review

Patch seems to be working well for me.

Antinoo’s picture

subscribing

blakehall’s picture

Status: Needs review » Reviewed & tested by the community

While I'm not positive it's the _best_ approach, the patch works as advertised.

(Since I'm the second tester, I've changed the status to RTBC)

pvhee’s picture

any news to include this in the module? i have the same error

watbe’s picture

subscribing

blup’s picture

subscribing

quicksketch’s picture

Status: Reviewed & tested by the community » Fixed

Thanks lesmana! If it works it works. ;-)

Committed to CVS so we can get a new release out.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.