版權所有:(xiaodaoxiaodao)藍小刀 ?? xiaodaoxiaodao@gmail.com

http://www.tkk7.com/xiaodaoxiaodao/archive/2007/09/17/145970.html

轉載請注明來源/作者

?

?

翻譯:Alfresco WCM Website Framework (WSF)

?

翻譯原文來源于http://wiki.alfresco.com/wiki/WSF

翻譯時間:This page was last modified 11:11, 10 September 2007

Wiki 的更新時間可以在頁面最底部看到。

?

第一次把英文的東西付諸于文字,恭喜自己一下先:)

?

由于個人翻譯水平經驗有限,歡迎批評指正。

?

WSF

內容

Alfresco WCM Website Framework (WSF)

The Alfresco Website Framework is (currently) an Alfresco Forge Project whose goal is to produce a basic website framework/skeleton that provides web developers a starting point for building new websites using Alfresco WCM. The WSF is Copyright of Alfresco and licensed under GPL.

Important Note: The WSF should currently be considered and viewed as an experimental playground as we explore ways of developing a series of best practices and design patterns for Alfresco WCM site development. Please keep this in mind as you begin to explore the WSF. Your feedback and suggestions are critical to the project's success. The eventual goal is to turn these into a robust and scalable platform for all Alfresco-based WCM activities.

Alfresco WCM Website Framework (WSF)

Alfresco Website Framework 當前是 Alfresco Forge Project下的一個項目,它的目標是為web站點構建一個基礎的框架,當web開發人員使用Alfresco WCM創建新的web站點時,web站點可以基于這個框架進行開發。WSF基于GPL協議,版權歸Alfresco所有。

注意: WSF 現在還在測試驗證中,我們正在研究其他的更好的使用Alfresco WCM 進行站點開發的方法,所以在你考慮使用WSF 之前,最好三思。同時希望你能夠提供一些反饋和意見,這對于我們會非常有用。我們的最終目標是為所有基于Alfresco WCM的應用建立一個健全可升級的平臺。

NEWS

  • WSF 2.0 Development to Commence : We're going to start working on the next version of WSF and have created a wiki page to capture our design goals and plan for achieving them at WSF Development.
  • Roadmap Updated : The roadmap has been updated with some new thoughts on the web presentation framework and some possible features.

新聞

  • WSF 2.0 開始開發 : 我們即將著手與WSF 下一個版本的開發,并且創建了一個wiki網頁,用來記錄開發目標和一些WSF Development的開發計劃。
  • Roadmap 更新 : roadmap上添加了一些關于web表示層的新想法和一些可能的特性。

?

WSF Features

  • Dynamic Navigation Channels
    • Three-level site navigation tree: Modeled and managed as web content.
    • Horizontal, Vertical Navigation: DHTML drop down menus and breadcrumbs.
  • Content Lists
    • Latest Content: Content list based on timestamp
    • Channel Content List: List of content under centain channels/
    • Multimedia File List: Embedded Flash Player lists videos and audio files.
    • Alfresco Documents: Traditional alfresco document list (via Open Search)
    • Featured Content List: Highlight a specific article to be featured on the front page.
  • Single Content View
    • Content Details
    • Picture of The Day: Supports slide show of multiple pictures.
    • Message of The Day: Single text block.
  • Sitemap
    • Implements Google Sitemap
  • Site Treeview
    • Treeview of all site assets and their properties.
  • Site Statistics
    • Display metrics related to site dynamic content.
  • Map Mashup
    • Display dynamic content (user profile) on Yahoo map.
  • Content Syndication
    • Alfresco document feed via Open Search REST API.
    • Alfresco WCM web content feed (Articles) in RSS format.
  • Site Preview
    • Site Preview toolbar
  • Site Configuration
    • Many site parameters are configurable e.g. style, header, footer, navigation, tool bar, locale etc.

WSF 特性

  • 動態導航頻道
    • 三層站點導航樹:作為web內容被設計和管理。
    • 水平,垂直導航:DHTML 下拉菜單和breadcrumbs 面包屑式導航。
  • 內容列表
    • 最新內容:基于時間戳的內容列表。
    • 頻道內容列表:某個頻道的內容列表。
    • 多媒體文件列表:Flash Player文件列表視頻和音頻文件。
    • Alfresco 文檔::傳統alfresco 文檔列表(通過Open Search自定義搜索引擎)
    • 特殊內容列表:在前端頁面高亮顯示指定的一篇文章。
  • 單個內容視圖
    • 內容詳細
    • 每日圖片:支持多個圖片幻燈片顯示。
    • 每日消息:單個文本塊。
  • 站點地圖
    • 實現自Google網站地圖
  • 站點樹狀顯示
    • 顯示所有的站點資源和屬性。
  • 站點統計
    • 顯示站點動態內容統計信息。
  • 地圖Mashup
    • 顯示基于Yahoo 地圖的動態內容(用戶代理)
  • 內容Syndication
    • Alfresco 文檔feed 通過Open Search REST API.
    • Alfresco WCM RSS 格式的web 內容feed (文章)
  • 站點預覽
    • 站點預覽工具欄
  • 站點配置
    • 很多站點參數是可配置的:例如style, header, footer, navigation, tool bar, locale 等等。

Installation

1.? The code from the SVN server includes a pre-generated demo-website.war file under the "extra" folder. You can freely use this and skip the following three steps. If you wish to build from scratch, please read on.

2.? Setup three environment variables

1.? ALFRESCO_REPOSITORY -- points to the root folder of your local alfresco svn repository.

2.? TOMCAT_HOME -- points to your alfresco tomcat home folder.

3.? VIRTUAL_TOMCAT_HOME -- points to your virtual alfresco tomcat home folder.

3.? Run ant script to build your alfresco instance.

4.? Run ant script under alfresco/core.

1.? If you point ALFRESCO_REPOSITORY to Enterprise HEAD, run ant -f build-head.xml build-demo-website

2.? For others, run ant build-demo-website

安裝

  1. SVN服務器上拿到的代碼含有一個demo-website.war 文件,位于"extra" 文件夾下。你可以自由使用這個war包并且跳過下面的三步。如果你希望從代碼重新創建,那么繼續往下讀。
  2. 創建三個環境變量Setup three environment variables
    1. ALFRESCO_REPOSITORY – 指向你本地alfresco svn資源的根目錄。
    2. TOMCAT_HOME – 指向你的alfresco tomcat根目錄。
    3. VIRTUAL_TOMCAT_HOME – 指向你的virtual alfresco tomcat 根目錄。
  3. 運行ant 腳本以便創建alfresco實例。.
  4. alfresco/core.目錄中運行ant 腳本
    1. 如果你把ALFRESCO_REPOSITORY 指定到 Enterprise HEAD, 運行ant -f build-head.xml build-demo-website
    2. 指定到其它路徑, 運行ant build-demo-website。

Uploading Site and Forms:

Create and configure new web forms with XSD files under folder contentmodels and associate them with the corresponding XSLs under folder templates. When setting up web forms, take all default values except for the Output path pattern.

1.?

??? 1.? Web form: article.

??????? 1.? Content output path pattern: /${webapp}/content/article/${name}.xml

2.? Template: article.xsl Output path pattern: /${webapp}/content/article/${name}.${extension}

3.? Template: article-list.xsl Output path pattern: /${webapp}/content/article/${name}-list.jsp

4.? Template: article-feature.xsl Output path pattern: /${webapp}/content/article/${name}-feature.jsp

5.? Template: article-rss.xsl Output path pattern: /${webapp}/content/article/${name}-rss.xml

??? 2.? Web form: news-flash.

??????? 1.? Content output path pattern: /${webapp}/content/news-flash/${name}.xml

2.? Template: news-flash.xsl Output path pattern: /${webapp}/content/news-flash/${name}.${extension}

3.? Template: news-flash-list.xsl Output path pattern: /${webapp}/content/news-flash/${name}-list.jsp

4.? Template: news-flash-feature.xsl Output path pattern: /${webapp}/content/news-flash/${name}-feature.jsp

??? 3.? Web form: multi-media.

??????? 1.? Content output path pattern: /${webapp}/content/multi-media/${name}.xml

2.? Template: multi-media-list.xsl Output path pattern: /${webapp}/content/multi-media/${name}-list.${extension}

??? 4.? Web form: navigation.

??????? 1.? Content output path pattern: /${webapp}/content/navigation/${name}.xml

2.? Template: navigation-sitemap.xsl Output path pattern: /${webapp}/content/navigation/${name}-sitemap.xml

3.? Template: navigation-menu.xsl Output path pattern: /${webapp}/content/navigation/${name}-menu.${extension}

??? 5.? Web form: motd.

??????? 1.? Content output path pattern: /${webapp}/content/motd/${name}.xml

2.? Template: motd.xsl Output path pattern: /${webapp}/content/motd/${name}.${extension}

??? 6.? Web form: potd.

??????? 1.? Content output path pattern: /${webapp}/content/potd/${name}.xml

2.? Template: potd.xsl Output path pattern: /${webapp}/content/potd/${name}.${extension}

??? 7.? Web form: profile.

??????? 1.? Content output path pattern: /${webapp}/content/profile/${name}.xml

2.? Template: profile.xsl Output path pattern: /${webapp}/content/profile/${name}.${extension}

??? 8.? Web form: site-configuration.

??????? 1.? Content output path pattern: /${webapp}/content/site-configuration/${name}.xml

??????? 2.? Create a new web project and associate it with all eight web forms we just created.

??????? 3.? Bulk import the "demo-website.war" file.

4.? Create a site-configuration content item using web form, site-configuration, and name it as SC and put it under "/content/site-configuration". You can just create a dummy one with the name SC and then update it with the SC.xml under extra folder.

5.? Create a navigation content item using web form, navigation, and name it as NavigationTree and put it under "/content/navigation". Again, you can just create a dummy one and update it with NavigationTree.xml under extra folder. If you want to use different name, you then need to adjust the navigation setting in SC.xml.

6.? Create web content, MOTD, POTD, News flash, Article etc. and put them under corresponding folders under "/content". To make news-flashes and articles available for channel pages, you need to edit your navigation content item and link them as content links (Check Feature option if you want them to be displayed as feature items). For MOTDs and POTDs, you can do the channel association when you edit them.

上傳站點和表單:

contentmodels 文件夾下使用XSD文件創建和配置新的web表單,并且在templates文件夾下關聯到相應的XSLs文件。 當創建web表單之后,除了輸出路徑模式之外的其它值可以使用缺省值。

  1. ?
    1. Web 表單: article.
      1. 內容輸出路徑模式: /${webapp}/content/article/${name}.xml
      2. 模板: article.xsl 輸出路徑模式: /${webapp}/content/article/${name}.${extension}
      3. 模板: article-list.xsl 輸出路徑模式: /${webapp}/content/article/${name}-list.jsp
      4. 模板: article-feature.xsl 輸出路徑模式: /${webapp}/content/article/${name}-feature.jsp
      5. 模板: article-rss.xsl輸出路徑模式: /${webapp}/content/article/${name}-rss.xml
    2. Web 表單: news-flash.
      1. 內容輸出路徑模式: /${webapp}/content/news-flash/${name}.xml
      2. 模板: news-flash.xsl 輸出路徑模式: /${webapp}/content/news-flash/${name}.${extension}
      3. 模板: news-flash-list.xsl 輸出路徑模式: /${webapp}/content/news-flash/${name}-list.jsp
      4. 模板: news-flash-feature.xsl 輸出路徑模式: /${webapp}/content/news-flash/${name}-feature.jsp
    3. Web 表單: multi-media.
      1. 內容輸出路徑模式: /${webapp}/content/multi-media/${name}.xml
      2. 模板: multi-media-list.xsl 輸出路徑模式: /${webapp}/content/multi-media/${name}-list.${extension}
    4. Web 表單: navigation.
      1. 內容輸出路徑模式: /${webapp}/content/navigation/${name}.xml
      2. 模板: navigation-sitemap.xsl 輸出路徑模式: /${webapp}/content/navigation/${name}-sitemap.xml
      3. 模板: navigation-menu.xsl 輸出路徑模式: /${webapp}/content/navigation/${name}-menu.${extension}
    5. Web 表單: motd.
      1. 內容輸出路徑模式: /${webapp}/content/motd/${name}.xml
      2. 模板: motd.xsl 輸出路徑模式: /${webapp}/content/motd/${name}.${extension}
    6. Web 表單: potd.
      1. 內容輸出路徑模式: /${webapp}/content/potd/${name}.xml
      2. 模板: potd.xsl 輸出路徑模式: /${webapp}/content/potd/${name}.${extension}
    7. Web 表單: profile.
      1. 內容輸出路徑模式: /${webapp}/content/profile/${name}.xml
      2. 模板: profile.xsl 輸出路徑模式: /${webapp}/content/profile/${name}.${extension}
    8. Web 表單: site-configuration.
      1. 內容輸出路徑模式: /${webapp}/content/site-configuration/${name}.xml
  2. 創建新的web工程,并把它關聯到剛才創建的8web表單。
  3. 批量導入"demo-website.war" 文件。
  4. 使用site-configuration這個web表單創建一個站點配置,命名為SC并把它放到 "/content/site-configuration"文件夾下。你也可以創建一個臨時文件,命名為SC,然后在其它文件夾下把它更新為SC.xml 。
  5. 使用navigation 這個web表單創建一個導航內容,命名為NavigationTree并把它放到"/content/navigation"文件夾下。同樣的,你也可以創建一個臨時文件,在其它文件夾下把它更新為NavigationTree.xml。 如果你希望使用別的名字,可以在SC.xml.文件中進行配置。
  6. 創建web 內容, MOTD, POTD, 新聞flash, 文章等等,并把它們放到"/content"下的相應文件夾下。為了讓頻道頁面可以使用新聞flash 和文章,你需要編輯導航內容項并通過內容鏈接鏈接到它們 (如果希望它們可以作為特征項顯示請查看特征選項).。對于MOTDs POTDs, 當你編輯它們的時候就可以關聯到相應的頻道。.

Roadmap

As we look towards evolving WSF, we hope to introduce a full-featured web development framework, AJAX support, widgets, skinnable UI templates and more.

Here are some ideas:

  • Web Development Framework : It would be beneficial to integrate WSF with one (or more) web frameworks such as Tapestry, Cocoon, Struts, etc. One key design goal, however, is that while support for an MVC architecture is desirable, we don't want to "slow down" the development process by requiring that the controllers be compiled. As such we're looking for a Java-compatible MVC web development framework that perhaps leverages dynamic languages. We're leaning towards using Groovy and Grails.
  • Dynamic Website : Dynamic content selection using [Web Scripts] as the back-end components and a front-end tag library.
  • Skinnable UI : We wish to establish CSS and UI conventions that facilitate the process of "skinning" or branding the website.
  • AJAX Support : As we look to add more interactivity to WSF, it would be ideal to use AJAX and DHTML techniques and integrate them into the content model and upcoming WCM search features. Possible toolkits include GWT, MooTools, YUI, Prototype, Dojo, etc.
  • Content Syndication and Mashable APIs : No web framework in this day and age would be complete without support for syndication formats (RSS and ATOM) and APIs (using REST, XML, JSON). As such, a skeleton package of syndicators and APIs would be beneficial to developers.
  • User Generated Content : Support for comments, tagging, perhaps blogs, etc.
  • User Management : This is more of a nice-to-have, but it's possible to have Alfresco WCM offer the ability to create "community sites" as such user management becomes critical. We could use something like OSUser as the foundation for this.

導航地圖

當我們關注WSF的進展時, 我們期望可以引入完全輪廓的web開發框架,AJAX 支持,widgets,UI皮膚模板,等等。

下面是一些想法:

  • Web 開發框架 : 這對于在WSF中集成一個或多個框架例如Tapestry, Cocoon, Struts, 等等會比較有用。一個關鍵的設計點,作為一個理想的MVC體系,我們不希望由于需要控制器的被編譯而"slow down"開發過程。所以我們正在尋找Java可兼容的MVC web開發框架,這種框架可以提供動態語言支持。我們正傾向使用GroovyGrails.
  • 動態web站點 : 使用后臺組件[Web腳本]和前臺標簽庫實現動態內容選擇。
  • UI 皮膚 : 我們希望通過CSSUI協定可以web站點的皮膚化處理更容易一些。
  • AJAX 支持 : 我們希望WSF具有更好的交互性,所以在內容模型和WCM搜索特性中使用AJAX DHTML技術比較理想。一些可行的小工具包括GWT, MooTools, YUI, Prototype, Dojo, 等等。
  • 內容Syndication Mashable API : 一個不支持syndication格式(RSSATOM)APIs (使用REST, XML, JSON)web框架在今天來說是不完善的。所以,一個syndicators APIs 的基礎包對于開發人員來說非常有用。
  • 用戶內容創建 : 支持注釋,標簽,可能還有博客等等。
  • 用戶管理 : 這會非常友好,不過Alfresco WCM 有可能創建一個"站點聯合",這就使用戶管理變的比較重要。我們可以使用一些類似OSUser的東東作為其基礎。

翻譯原文來源于http://wiki.alfresco.com/wiki/WSF



翻譯: Alfresco WCM Website Framework (WSF).pdf 下載地址:

翻譯: Alfresco WCM Website Framework (WSF).rar

? ?

?

版權所有:(xiaodaoxiaodao)藍小刀 ?? xiaodaoxiaodao@gmail.com

?