Revision 13702
Added by Aaron Marcuse-Kubitza over 10 years ago
trunk/web/username_prefix.php | ||
---|---|---|
12 | 12 |
# remove padding used to visually separate elements:__x__@y__@url -> x@y@url |
13 | 13 |
$path = preg_replace('/\b__|__\b/', '', $path); |
14 | 14 |
|
15 |
# remove any comment prefix: c:x@url -> x@url |
|
16 |
# *note*: when URL is used without http:// , you must include a non-letter |
|
17 |
# in the comment (eg. c_:x@url) to work in Firefox |
|
18 |
$elems = explode(':', $path, 2); |
|
19 |
$path = array_pop($elems); # last (comment is first) |
|
20 |
|
|
15 | 21 |
# translate reverse @-paths into forward .-paths |
16 | 22 |
$path = implode(".", array_reverse(explode("@", $path))); |
17 | 23 |
|
Also available in: Unified diff
web/username_prefix.php: user2path(): added support for comment prefixes, which can be used to include term categories. note: when URL is used without http:// , you must include a non-letter in the comment (eg. c_:x@url) to work in Firefox.