Are there any good references for creating custom content types via modules in Drupal 5. I have had success with the tutorials via version 4.7 however I dont seem to get my custom content type to appear which I visit Create Content.

Any helpers, pointers to articles or posts much appreciated.

Comments

maybourne’s picture

  1. Login as user 1
  2. Install CCK module (if you haven't done so).
  3. go to admin/content/types/add
  4. Fill out all required fields.
  5. Verify content type shows up in admin/content/types
  6. Make sure you give appropriate permissions for your content type.

Voila! :)

pdjohnson’s picture

Thanks, I know about that, however I would rather use a module since I want to add some special features to the content type forms which wont be available via the CCK. So anyone out there done any content type modules in 5.0???

--Paul Johnson

nicolash’s picture

I would like my custom module to come up as a new content type (NO CCK), so I can enable other modules functionality for it. Are content types only for CCK nodes?

There doesn't seem to be any documentation on this...only for 4.7...

vm’s picture

wouldn't the audio module or video module which creates their own content be a good path to follow ? reverse engineering them a bit may be fruitful ?

nicolash’s picture

But I can't find anything in there that is obvious. Initially I thought it needed a node_type_safe call, but that is nowhere to be found in the audio module or installer. Apparently an entry in the node_type table is now required - I copied an existing entry and modified it to suit, but still no luck.

nicolash’s picture

Can anybody post some code that would create a new content type via a module. It doesn't actually have to do anything, just appear in the list of content types and by available for other modules to add functionality (i.e. Event, Location etc.).

Thanks in advance...