Good point. I had not got that far yet. My first concern
was to find a way to allow each module (or core for that matter) define
their icon file name and location. You will obviouslly need
a way to theme it once you have it in the menu structure and want to
display it. Like I said, I hope to be trying this soon so we'll
see how it goes.<br>
<br>
<br><br><div><span class="gmail_quote">On 1/9/06, <b class="gmail_sendername">markus_petrux</b> <<a href="mailto:development@drupal.org">development@drupal.org</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Issue status update for<br><a href="http://drupal.org/node/42493">http://drupal.org/node/42493</a><br>Post a follow up:<br><a href="http://drupal.org/project/comments/add/42493">http://drupal.org/project/comments/add/42493
</a><br><br> Project: Drupal<br> Version: cvs<br> Component: menu system<br> Category: feature requests<br> Priority: normal<br> Assigned to: Anonymous<br> Reported by: markus_petrux<br> Updated by: markus_petrux
<br> Status: active<br><br>Looks good, but how would you pass the icon to the theme function<br>(theme_menu_item). Creating a new function menu_item_icon (similar to<br>menu_item_link) ?<br><br><br><br><br>markus_petrux
<br><br><br><br>Previous comments:<br>------------------------------------------------------------------------<br><br>Wed, 28 Dec 2005 03:03:16 +0000 : markus_petrux<br><br>I ame across this idea when thinking of a way to assign icons to menu
<br>items. Maybe it could be done with a module, but that's not easy<br>because it is not possible to hook into the menu item form.<br><br><br>...or is there an easier way?<br><br><br>Thanks<br><br><br><br><br>------------------------------------------------------------------------
<br><br>Mon, 09 Jan 2006 18:29:53 +0000 : Eglish<br><br>We want 4.7 out the door ASAP, i'm changing this to a feature request<br>for cvs not 4.7.0-beta2.<br><br><br><br><br>------------------------------------------------------------------------
<br><br>Mon, 09 Jan 2006 19:08:43 +0000 : der<br><br>I had an email discussion with the menu maintainer several weeks ago on<br>this topic. And he confirmed that it should be as easy as adding an<br>'icon' field to the menu structure in the existing menu hook. In other
<br>words, he didn't think there would be any changes in core. I have not<br>yet tried this myself but I plan to give it a shot soon. Here's what<br>the hook code would look like.<br><br><br> $items[] = array(<br> 'path' => 'admin/user/create',
<br> 'title' => t('add user'),<br> 'callback' => 'user_admin',<br> 'access' => $admin_access,<br> 'icon' => 'actions/contact-new.png',<br> 'type' => MENU_LOCAL_TASK);<br><br>
<br><br><br></blockquote></div><br>