Active
Project:
Content Profile
Version:
6.x-1.x-dev
Component:
Base module
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
17 Jun 2009 at 13:41 UTC
Updated:
20 Jun 2009 at 23:45 UTC
It always annoys me that the node add pages for content profile node types still appear in the menu hierarchy.
Here is a snippet that solved this by implementing hook_menu_alter (module's name is 'misc_code'):
/**
* Implementation of hook_menu_alter
* @return
*/
function misc_code_menu_alter(&$items) {
// disable content profile node add pages
foreach (content_profile_get_types('names') as $type => $typename) {
$items['node/add/' . $type]['access callback'] = FALSE;
}
}
Not sure if content profile should disable these pages by default
Comments
Comment #1
netentropy commentedWhere did you place this code?
I think this is what my issue is concerning.
If a user only gets 1 content profile then there should be an edit profile link not a create content > profile