Closed (fixed)
Project:
Content Construction Kit (CCK)
Version:
6.x-3.x-dev
Component:
nodereference.module
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
24 Sep 2009 at 22:46 UTC
Updated:
9 Oct 2009 at 18:50 UTC
Comments
Comment #1
markus_petrux commentedYou need to do this using custom validation code. You can try appending an #element_validate callback to node reference fields, or you can do it in hook_nodeapi('validate'). Please, search the Drupal APIs reference for more details.
http://api.drupal.org
You can probably add #element_validate callback (or #validate callback) using hook_elements() altering the elements implemented by node reference module widgets. You may alter the weight of your module to a number higher than nodereference module weight (do this in hook_enable).
Comment #2
tomsm commentedThank you for the information.
Maybe "No duplicates" for multiple CCK fields would be a good feature request?
Comment #3
markus_petrux commentedI'm afraid to say yes to most of the feature requests that land in the CCK queue (even if someone else provides the patches) because almost everyone but me here is focused on D7, and I do have more work than I really can.
I would even say CCK2 is somehow feature frozen for that reason.