[development] One core, many distributions
larry at garfieldtech.com
Mon Nov 21 09:22:21 UTC 2005
Actually, I'd suggest something even easier. In 4.7, there's a menu settings
fieldset for every node. First, expand that to tie to just ONE menu instead
of all of them, for size reasons. Call that menu "Site Structure" (or
"Navigation" <g>). Then any page that gets put into that menu automagically
gets a dynamic alias (read: not stored in path_alias) of that menu location.
So a node with ID 47 called "stuff" that is placed in the menu with parent:
Site Menu > mysection > mysubsection
will be accessible via both node/47 AND mysection/mysubsection/stuff.
That way the node_alias table doesn't get hammered, there's a clean interface
to it, it makes logical sense for a deep site structure as well as a shallow
one, and you also get to leverage all of the menu module magic. In fact, set
that site menu to be the Primary Links menu, thanks to Richard's great new
patch, and you automagically get your primary and secondary links based on
your URLs. (If you don't want them to be, though, you don't have to.) That
should scale as large as large as sites that need a unique non-numeric name
for everything. (Eg, drupal.org has no need to give a string name to every
The path module can stay as is for adding additional paths to a page if needed
(say, the diffandpatch page which we do want to have a nice short URL but
doesn't belong in the primary links), but won't be necessary for most
usernames, frankly, should be a built-in feature. It should be trivial to
tweak user.module to accept an ID or name, since both are required to be
unique anyway. Besides, path_alias doesn't scale for larger sites.
(Drupal.org has over 40,000 users, if I'm interpreting the URL correctly.
pathauto would die horribly.)
That eliminates the two largest needs for path/pathauto. The rest are
taxonomy categories, which could also be automated the same was as user, or
not, take your pick. :-) Either way it would clean up the largest needs for
path/pathauto, and offer additional functionality.
I think it's too late to put that into 4.7, but what do you think?
On Monday 21 November 2005 02:43 am, Bèr Kessels wrote:
> So, not
> store /tagadelic/chunk/Foo, /tagadelic/chunk/Foo+Bar
> /tagadelic/chunk/Foo,Bar /tagadelic/chunk/Foo+Faa and so on, but rather
> just match Foo, Faa, Bar against the db on call of that page.
Larry Garfield AIM: LOLG42
larry at garfieldtech.com ICQ: 6817012
"If nature has made any one thing less susceptible than all others of
exclusive property, it is the action of the thinking power called an idea,
which an individual may exclusively possess as long as he keeps it to
himself; but the moment it is divulged, it forces itself into the possession
of every one, and the receiver cannot dispossess himself of it." -- Thomas
More information about the development