Posted by neilolsen on September 4, 2011 at 5:15pm
2 followers
Jump to:
| Project: | Image Picker |
| Version: | 7.x-1.x-dev |
| Component: | Miscellaneous |
| Category: | feature request |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | active |
Issue Summary
Hi,
I am wondering:
1. Is there any way to create a link where it will open a page that contains all Public Groups / Images?
2. Is it possible to include one's Public Groups / Images link to their user profile page?
Thank you!
Regards, Neil.
Comments
#1
The best way to make bespoke changes to the way Imagepicker (or any other module) does things is to write a helper module for your site (eg my_helper_module) and use hook_menu() to create a path and hook_user_view() to create an entry in the user profile page
This is not tested, but it should work:
function my_helper_module_menu() {$items['user/%imagepicker_uid/my_helper_module/images/browse_public'] = array(
'title' => 'Browse Public',
'description' => 'Browse public imagepicker files.',
'page callback' => 'imagepicker_user_page',
'page arguments' => array(1, 3, 4, 5),
'access callback' => 'imagepicker_access_user_public',
'type' => MENU_CALLBACK,
'file' => 'imagepicker.user.inc',
);
return $items;
}
I haven't used hook_user_view() but there is information on how to add stuff to the user profile in api.drupal.org, search for "hook_user_view". Basically you create a function my_helper_module_user_view() and add whatever you want to appear on the profile page.