Closed (fixed)
Project:
Drupal core
Version:
6.x-dev
Component:
menu system
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
24 Jul 2007 at 00:12 UTC
Updated:
22 Jan 2008 at 18:12 UTC
Jump to comment: Most recent file
Comments
Comment #1
yasheshb commentedharking:
hello, i've fixed the code (patch attached) to incorporate url aliases as paths in menu items. the code will work as long
as one does not edit the url alias. the reason being
the path (link_path) determines the router_path for the menu item.
i've added code in the menu.module to check if the menu path is a url alias. if so, it's validated.
the menu path is then given to menu_link_save function in menu.inc where it's router_path is determined.
here again, i'm checking to see if the menu path (link_path) is a valid url alias, if so, i use the
source of the url alias to calculate the router path.
however, if one edit's the url alias - i.e. either changing the source or destination,
then one needs to update the tables for menu_links. this could be implemented with
a hook invoked by the path module.
hence this is a partially working solution, would appreciate feedback from community on
moving further.
rgd.
yashesh
Comment #2
pwolanin commentedThe menu link editing form says that you must enter a Drupal path. Aliases should never be put in this table.
A possible solution would be to look up the alias and save the Drupal path in the DB. This should be done in menu.module, and not touch any code in menu.inc.
Comment #3
webernet commentedFixed in 6.x -- the alias is converted to the drupal path.
Comment #4
Anonymous (not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.