Brainstorming...
Instead of having so many options for altering aliases (lowercase, separator, strings to remove, punctuation, etc.), what if we re-thought each of these things as an 'alteration', much like ImageAPI has 'transformations' that can be applied to an image. And think of each Pathauto pattern as an 'Image style'. For Pathauto, we'd start out with a few different types of transformations:
1. Change case
2. Find/replace words/strings
3. Find/replace character types
By default we'd have the following transformations enabled as well:
Change case (lowercase)
Find/replace words (a/an/as/at/etc => '')
Find/replace character types (spaces + punctuation => '-')
Trim length
Trim component length
Like Image API in core, there are default settings/transformations, and each pattern could override the settings to add or remove specific transformations. And users can re-order the weight of transformations as well.
Other modules (like Transliteration) could provide their own alias transformations and make them available to Pathauto via a hook.
A lot of this would probably happen on 7.x-2.x development. Just want to get feedback for now.
| Comment | File | Size | Author |
|---|---|---|---|
| #4 | screenshot_051.png | 52.09 KB | dave reid |
Comments
Comment #1
gregglesI think the UI might be a bit intense, but this could exist in a separate "extreme alias control" module, perhaps.
Dave mentioned http://7x.local/admin/config/media/image-styles as an example of a similar UI.
Comment #2
dave reidYeah to start this out it would only be used for the default manipulation settings and we wouldn't include any ui to override the settings for each pattern.
Comment #3
Freso commentedI've had pretty much the exact same thought, Dave. :) (And I actually thought I'd recorded it in one of the issues floating about... I know I talked to Greg about it, anyway.) This would indeed be the way to go, IMHO.
Comment #4
dave reidHere's a mockup of what the revised 'Settings' page would look like with Pattern alterations.
Comment #5
klonosI had forgotten about this one. Your latest reply in #821188: Individual settings for patterns brought it back in memory. Any progress?
Comment #6
dave reidI think we'll have to wait until a 7.x-2.x branch of pathauto for this. It may be too much change to handle before we need to have a 7.x-1.0 release.
Comment #7
klonosOk, sounds fair. Thanx for taking the time to reply Dave.
BTW, you are on fire today ;) working in burst mode.
Comment #8
tsvenson commentedSubscribing, this is going to make things so much better.
Comment #9
dave reidPostponed until 7.x-2.x.
Comment #10
mably commentedComment #12
mably commentedComment #13
mably commentedComment #14
mably commentedComment #15
mably commentedComment #16
mably commentedComment #17
mably commentedComment #18
mably commentedComment #19
mably commentedComment #20
mably commented