Making custom fields available to CCK administration menus
Hi, this is Karl Giesing, aka Karlheinz. I'm the developer of the Discogs module: http://drupal.org/project/discogs I have a user who uses CCK, and would like to administer the fields I created, using CCK's "Manage Fields" and "Display Fields" menus. I did NOT create the fields using CCK, and was wondering if this is possible. Any ideas? I haven't found any documentation on how to do this. -Karl.
Please see http://drupal.org/node/101742 On Wed, Jan 26, 2011 at 9:39 PM, Karl Giesing <khzmusik@hotmail.com> wrote:
Hi, this is Karl Giesing, aka Karlheinz. I'm the developer of the Discogs module: http://drupal.org/project/discogs
I have a user who uses CCK, and would like to administer the fields I created, using CCK's "Manage Fields" and "Display Fields" menus. I did NOT create the fields using CCK, and was wondering if this is possible.
Any ideas? I haven't found any documentation on how to do this.
-Karl.
And the answer is, if you didn't create the fields using a CCK-based technique, then they're not fields, they're extra information attached to the node type, so they can't be managed via CCK. -Randy On Wed, Jan 26, 2011 at 11:45 PM, Carl Wiedemann <carl.wiedemann@gmail.com>wrote:
Please see http://drupal.org/node/101742
On Wed, Jan 26, 2011 at 9:39 PM, Karl Giesing <khzmusik@hotmail.com>wrote:
Hi, this is Karl Giesing, aka Karlheinz. I'm the developer of the Discogs module: http://drupal.org/project/discogs
I have a user who uses CCK, and would like to administer the fields I created, using CCK's "Manage Fields" and "Display Fields" menus. I did NOT create the fields using CCK, and was wondering if this is possible.
Any ideas? I haven't found any documentation on how to do this.
-Karl.
-- Randy Fay Drupal Module and Site Development randy@randyfay.com +1 970.462.7450
You can use hook_field_extra_weights() to reorder fields via the cck manage fields screen like the flag module. You should be able to hook_form_alter a link to your own, custom settings page into that interface as a convenience. On Jan 26, 2011 11:45 PM, "Carl Wiedemann" <carl.wiedemann@gmail.com> wrote:
Please see http://drupal.org/node/101742
On Wed, Jan 26, 2011 at 9:39 PM, Karl Giesing <khzmusik@hotmail.com> wrote:
Hi, this is Karl Giesing, aka Karlheinz. I'm the developer of the Discogs module: http://drupal.org/project/discogs
I have a user who uses CCK, and would like to administer the fields I created, using CCK's "Manage Fields" and "Display Fields" menus. I did NOT create the fields using CCK, and was wondering if this is possible.
Any ideas? I haven't found any documentation on how to do this.
-Karl.
function mymodule_content_extra_fields($type_name) { if ($type_name != 'blog') { return; } $extras = array(); $extras['add_comment'] = array( 'label' => t('Add comment'), 'description' => t('Content section') . ': ' . t('Link to the new comment form'), 'weight' => 0, ); $extras['plus1_widget'] = array( 'label' => t('Recommend'), 'description' => t('Content section') . ': ' . t('Link to recommend node'), 'weight' => 0, ); $extras['tweetmeme'] = array( 'label' => t('Retweet'), 'description' => t('Content section') . ': ' . t('TweetMeme button'), 'weight' => 0, ); $extras['service_links'] = array( 'label' => t('Save and Share'), 'description' => t('Content section') . ': ' . t('Service Links buttons'), 'weight' => 0, ); $extras['print_links'] = array( 'label' => t('Print Links'), 'description' => t('Content section') . ': ' . t('Print Links?'), 'weight' => 0, ); $extras['see-more'] = array( 'label' => t('See more'), 'description' => t('Content section') . ': ' . t('See more posts Links'), 'weight' => 0, ); $extras['categories'] = array( 'label' => t('Categories'), 'description' => t('Content section') . ': ' . t('Term links from Categories'), 'weight' => 0, ); $extras['related'] = array( 'label' => t('Related research'), 'description' => t('Content section') . ': ' . t('List of related research'), 'weight' => 0, ); return $extras; } Nancy Injustice anywhere is a threat to justice everywhere. -- Dr. Martin L. King, Jr. ________________________________ From: Karl Giesing <khzmusik@hotmail.com> To: development@drupal.org Sent: Wed, January 26, 2011 11:39:51 PM Subject: [development] Making custom fields available to CCK administration menus Hi, this is Karl Giesing, aka Karlheinz. I'm the developer of the Discogs module: http://drupal.org/project/discogs I have a user who uses CCK, and would like to administer the fields I created, using CCK's "Manage Fields" and "Display Fields" menus. I did NOT create the fields using CCK, and was wondering if this is possible. Any ideas? I haven't found any documentation on how to do this. -Karl.
participants (5)
-
Adam B. Ross -
Carl Wiedemann -
Karl Giesing -
nan wich -
Randy Fay