gdo aliases

We encourage users to post events happening in the community to the community events group on https://www.drupal.org.
Chris Charlton's picture

Who can I ask to hook us up with a GDO alias, like gdo/la and/or losangeles without a hyphen? I would think New York would like "ny" too.

Comments

the problem is getting

moshe weitzman's picture

the problem is getting drupal to use the new alias by default. i have not investigated how drupal5 picks an alias whern there are several for a given node
.

Branding

Boris Mann's picture

Moshe -- that's not really a big deal. It's more about being able to type it out, put it on print materials, or say it to someone out load.

at the mercy of the db

greggles's picture

Here it is:

SELECT src FROM {url_alias} WHERE dst = '%s' AND language IN('%s', '') ORDER BY language DESC

Assuming there is just one language for that alias...the database engine will just return the first row that was added to the database table, but that's not guaranteed to be consistent.

I believe MikeRyan had a patch back in the 4.7 timeframe to add a "weight" concept to the path alias table so that the return value could be consistent - though it didn't quite make it in (or was added and removed).

My feeling is that url_alias table should only have one alias for every internal path and that all other aliases should be in path_redirect (or similar) modules. As I think about this problem a little utility module which helped clean up the url_alias table to a single alias and then moved all others to path_redirect seems like a good idea...now to figure out the UI for it.

@greggles - a great UI has

moshe weitzman's picture

@greggles - a great UI has already been coded up. Just needs patch refresh and review and the usual core patch push. See http://drupal.org/node/147143

I added aliases - nyc and

moshe weitzman's picture

I added aliases - nyc and la

way cool

mike stewart's picture

thanks so much guys! this is way cool!

--
mike stewart { twitter: @MediaDoneRight | IRC nick: mike stewart }

FYI, the nyc alias isn't

kyle_mathews's picture

FYI, the nyc alias isn't working anymore (as of Sunday morning MDT). The la alias is working.

Kyle Mathews

Kyle Mathews

Odd - I just readded it.

moshe weitzman's picture

Odd - I just readded it.

Maintenance

Group organizers

Group categories

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds: