相冊制作
1. 使用Druapl版本:drupal-5.3.tar.gz
2. 使用到的模塊:cck-5.x-1.6-1.tar.gz,custom_pagers-5.x-1.7.tar.gz,imagecache-5.x-1.3.tar.gz,imagefield-5.x-1.1.tar.gz,thickbox-5.x-1.1.tar.gz,views-5.x-1.6.tar.gz,views_bonus-5.x-1.2-alpha1.tar.gz
3. 安裝Drupal和模塊:
CCK:選中Content,Image,Text
Core - optional:選擇Upload
Image:選擇Imagecache
Other:選擇Custom Pagers,Thickbox
Views:選擇Views,Bonus: grid view,Views UI
4. 創建Imagecache
Administer › Site configuration選擇Image cache,Preset namespace里輸入squarethumbnail,點擊Update preset。然后在Add a new action選擇Scale,點擊Update preset。然后在width里輸入100,height里輸入100,點擊Update preset。然后在Add a new action選擇Crop,點擊Update preset。width里輸入50,height里輸入50,X offset里輸入:center, Y offset里輸入:center,點擊Update preset。Preset namespace里輸入display,點擊Update preset。然后在Add a new action選擇Scale,點擊Update preset。然后在width里輸入650,height里輸入650,點擊Update preset。
5. 新建一個content type叫image并編輯,Add Field。Create new field,name為image,Field type選擇Image。Image path為image, Data settings中選擇Required。
6. 新建一個view
Name:Gallery
Description:an image gallery
Page中選擇:
Provide Page View
URL:gallery
View Type:Bonus:Grid View
Nodes per Page:24
Fields中選擇:
Node: Title
Image: image (field_image) Do not group multiple values(Handler)
Thickbox:squarethumbnail(Option)
Filters中選擇:
Node: Published
Node: Type Image(Value)
下面就可以新建Image了
posted on 2007-10-31 15:33
周銳 閱讀(865)
評論(0) 編輯 收藏 所屬分類:
PHP