, V4 v6 {, F7 [$ H
pathauto模块是自动产生路径别名的模块,装上这个模块以后,你可以节省为每 个文章添加别名的劳动。 下面介绍这个模块的使用教程。 首先看pathauto的整体配置如下: # h' `' M; D- i- L5 e5 V% z
1、常规设置: 常规设置包含很多需要设置的选项。 verbose:这个目前还没搞太清楚什么意思。
4 |2 R9 E7 a: M2 R* T, iSeparator: 当遇到空格或者特殊字符时,用这个分隔符来代替。
" L' h9 K6 A" e3 yCharacter case: 分两个选项,第一个是维持原状,第二个是都变成小写(这个主要针对英文)0 r) A5 x( Y8 [) ^% F
Maximum alias length: 别名的最大长度,推荐是100
9 M/ C: a, k- ^, S; s6 M" JMaximum component length: 组成别名的文本的最大长度,推荐是100" W; T: }0 J" y1 o
Maximum number of objects to alias in a bulk update: 当批量更新别名时,最大的更新数目,推荐是50。
* V" H( l" W2 M" k; ?update action:更新时产生别名的的方式。有三种,第一是维持原状,第二创建一个新的别名,但是留着原来别名的一些功能,第三创建一个新的别名,但是原来的别名删除。
8 v9 F+ |; j: f2、punctution settings(特殊符号的设置方式) double quotes ":有三个选项,第一“remove”就是删除这个双引号,第二 replace by separator,就是让前面“常规设置”里设置的Separator来代替这个 双引号,第三,no action(do not replace)维持原状不变。 下面的所有的特殊标点符号的设置跟上面的说明类似。
( m! O9 O3 [# n; n& K8 p3、blog path settings(blog的别名路径的设置) pattern for blog page paths:这个用于设置blog别名路径的模式。. m/ q9 h* D& o3 k: p$ h4 O) Q0 f
"blogs/[user-raw]"这个值表示别名的路径是blogs/经过过滤的用户名,这种模 式。
7 n4 C+ V' M) y* M* i7 {! r后面的变量值[user-raw]可以用下面replacement patterns里的值来代替。' [% s j' S% q: O
bulk generate aliases for blogs that are not aliased:这个选项选中的作用就是给那些没有别名的blog页面,批量产生别名。$ t: Z2 D) V) N9 o/ v. c9 r* g
internal feed alias text(leave blank to disable):内部rss种子需要用的别名形式。 , n6 p" y! ^+ O
4、forum path settings(forum的别名路径设置)' |0 \2 c- a5 l$ ^
用法参考上面的blog路径的设置
5 x$ ^, z6 _: N' s5、node path seettings(node的别名路径设置)- |) b( N. u" f9 Z# L3 N( M
用法也参考上面的blog路径的设置
% G6 N0 A( d' W2 _$ P' `9 U6、category path settings(category的别名路径设置)
# y3 ^# L" d' ?5 C0 k; a用法也参考上面的blog路径的设置 7、user path settings(user的别名路径设置) 4 E$ l) _" i# V: B B) ?9 W
用法也参考上面的blog路径的设置 2 \$ ]+ H9 u1 v) y* P7 [+ {
下载地址:http://drupal.org/project/pathauto K* m& b w7 s- e! ]6 J
$ w4 O! q: W( ?' i$ k
$ s5 v ~; F) i( ~: [2 v8 r+ w9 _4 S% F: M2 V3 C! M, c% r7 g8 [
# W% L$ [4 u5 @( j7 S$ I% d; s
7 Y/ K( Q/ b9 q) K1 c8 R8 ]: \3 mThe Pathauto module automatically generates URL/path aliases for various kinds of content (nodes, taxonomy terms, users) without requiring the user to manually specify the path alias. This allows you to have URL aliases like /category/my-node-title instead of /node/123. The aliases are based upon a "pattern" system that uses tokens which the administrator can change. Requirements- Token0 p# T+ d& O/ J) n0 X
VersionsThe 7.x-1.x and 6.x-2.x branches are currently accepting new feature requests and are kept in sync as much as possible. The 6.x-1.x branch is feature-locked and will only add bug fixes and security updates if needed. Known issuesRecommended modules- Redirect (D7) / Path Redirect (D6) when installed Pathauto will provide a new "Update Action" in case your URLs change. This is the recommended update action and is considered the best practice for SEO and usability.
- Global Redirect ensures that your content is only visiable at the one, best URL possible (i.e. requests for node/2 are forwarded to "alias-for-node-2").
- Pathologic (untested, but may help with updating outdated links in existing content)
- Sub-pathauto (D7) / Sub-path URL Aliasing (D6) provides a way to use one alias for multiple URLs as long as the so that "node/1" is aliased to "about-my-site" then you can use "about-my-site/edit" to access "node/1/edit". Neat!
- Transliteration is useful if your site is likely contain characters beyond ASCII 128 and you want them transliterated into ASCII 128. (For Pathauto 6.x-1.x this feature is handled by the Pathauto module, see the README.txt for more details).
$ M; j1 Y9 E2 @/ d# l8 l# ]* \ Co-MaintainersPathauto was originally written by mikeryan and maintained by Greg Knaddison (greggles). It is currently co-maintained by Frederik 'Freso' S. Olesen and Dave Reid. Pledges#D8CX: I pledge that Pathauto will have a full Drupal 8 release on the day that Drupal 8 is released. #D7CX: I pledge that Pathauto will have a full Drupal 7 release on the day that Drupal 7 is released - PLEDGE FULFILLED! #D7AX - I pledge to make this module as accessible as it can be. If you find any flaws, please submit an issue and tag it D7AX. Help me fix them if you can.
2 @% x+ S. A8 z( ~( O) ^8 }9 p. j M% ^: }2 _3 @3 X1 O% U
~" E5 n2 A0 T; D, |1 @6 A
|