It would be nice if the size of each variable was configurable. This is to avoid having ginormous URL's created for lengthy titles.

Suggestion for the variable format [title:30].

Thanks.

Comments

mikeryan’s picture

Assigned: Unassigned » mikeryan
eaton’s picture

A minor note -- this makes it easy to create duplicate alias entries. Appending '_#' to the entry, where where # is 1 for the first DUPLICATE entry, 2 is the second DUPLICATE entry, and so forth, would duplicate the behavior in most blogging software. In particular, it would make it possible to easily mirror Movable Type's archiving structure.

mikeryan’s picture

Pathauto already appends sequence numbers for duplicate paths.

mikeryan’s picture

That approach would be a little tricky - I've implemented a maximum length for the full alias - if that isn't sufficient for your needs, how about a global maximum component length? I.e., with a pattern of [cat]/[title], a max component length of 10, and a node "This title is too long" in category "Random category", the generated path would be "random_cat/this_title"...

Gabriel R.’s picture

mikeryan: #4 makes perfect sense, it's what I was looking for.

mikeryan’s picture

Status: Active » Fixed

OK, I've implemented a maximum component length in addition to the maximum total length.

mikeryan’s picture

Status: Fixed » Closed (fixed)