drupal 6 my experience

33
W.G. Paseman 2/23/2012 Drupal (6) my experience 2/23/12 1 © W. G.Paseman

Upload: bill-paseman

Post on 05-Dec-2014

1.506 views

Category:

Technology


3 download

DESCRIPTION

 

TRANSCRIPT

Page 1: Drupal 6 my experience

W.G. Paseman 2/23/2012

Drupal (6) my experience

2/23/12 1 © W. G.Paseman

Page 2: Drupal 6 my experience

Agenda   My Experience   Drupal (6) Content Authoring

 Web Site 1.0 – Microsoft Frontpage   Edit Hierarchical Document on your computer

 Web Site 2.0 – Drupal   CMS (Content Management System) in the cloud

  Drupal (6) Site Development  Web Application –SAAS  Choosing a Development Process  Selecting a Host  Deploy  Creating a UI

2/23/12 2 © W. G.Paseman

Page 3: Drupal 6 my experience

W.G. Paseman

Drupal (6) Content Authoring

2/23/12 3 © W. G.Paseman

Page 4: Drupal 6 my experience

Web Site 1.0/Site Example/Frontpage

2/23/12 © W. G.Paseman 4

Menus Word Class Styled Text

Hypertext Links

Three Column Layout

Page 5: Drupal 6 my experience

Web Site 1.0/Authoring/FrontPage

2/23/12 © W. G.Paseman 5 WYSIWYG Editor

Directory Style Content Organization

Page 6: Drupal 6 my experience

Web Site 1.0 - Edit a Hierarchical Document on your computer

  Site Example: paseman.com   Multiple users browse a site containing a File System of hyperlinked documents.   Directory Hierarchy maps to Site Structure

  Authoring: Frontpage   Provides a “Word – like” WYSIWYG model of Web document.   Generates HTML automatically   Deploys Directories/Files to Host   CLIENT ONLY SOFTWARE

  Architecture   Client: Browser(Http(Url))   Transport: html+ css+ javascript+ img + …

  <div class="content"><p>Some Content<p></div>

  Server: Two Tier Architecture   Tier 1: Web Server - Presentation   Tier 2: File System - Storage

  <div class="content"><p>Some Content<p></div> 2/23/12 6 © W. G.Paseman

Page 7: Drupal 6 my experience

Web Site 1.0/Authoring/Issues   Novelty

  People don't come back to static Web pages so I need to continually publish new stuff.   Manage Volume

  I have more content than fits on my home page   I have more content than I want to display at one time.

 e.g. Hermitage displays only 150K items at a time of a 3M item collection   Fixed File hierarchies are a poor organizational principle for large volumes of data

  Manage Variety of Structured Data   I have fundamentally different types of content, and I need a checklist for each type to make sure it

is filled in consistently and correctly.  Destinations have location, theme, best times, categories, contact….  Tours are a collection of Destinations…  Products have prices…

  Volume and Variety mean I should keep content in a relational (SQL) database.   Manage Workflow

  Version Control: I need to update old stuff   Revision Control: I need controlled release of new content (E.g. Weekly issues)   I manage different groups, in different locations, each responsible for a portion of the site.

  Workflow is easier to manage in a centralized fashion, so I ought move CMS behavior from client to the server. This means I ought add a “behavior” tier to the server.

2/23/12 7 © W. G.Paseman

Page 8: Drupal 6 my experience

Web Site 2.0/Site Example/Drupal View

2/23/12 © W. G.Paseman 8

Taxonomy - Count of Product Content Types - SQL Project

Grid “View” -  Destination Content Type -  SQL Select & Sort

Slideshow“View” -  Banner Content Type -  SQL Select & Sort

  How Drupal uses the SQL database for the reader (user)   What happens if we drill down here?

Page 9: Drupal 6 my experience

Web Site 2.0/Site Example/Drupal Node

2/23/12 © W. G.Paseman 9

Wysiwyg Stuff -  Embedded Media -  Formatted Text -  Hyperlinks

User Defined Fields -  Acts as Checklist -  Aids Search -  Aids Integration -  Types include

- Text - Picture - Location

Page 10: Drupal 6 my experience

Web Site 2.0/Authoring/ Content Management System/Drupal

2/23/12 10 © W. G.Paseman

Navigate content as rows in a Relational DB Not Files in a File System

Multiple Content Types Multiple Authors Release Management

 How Drupal uses the SQL database for the author  What happens if we drill down here?

Page 11: Drupal 6 my experience

Web Site 2.0/Authoring/Drupal/Node WYSIWYG Functionality

2/23/12 © W. G.Paseman 11

  Code for this editor resides on the server, not the client.   It is accessed by the authors through their browsers.   In my case, the same code is accessed by an author in a

Saratoga living room and an author in a Cebu Cybercafe.

Page 12: Drupal 6 my experience

Web Site 2.0/Authoring/Drupal/CCK

2/23/12 © W. G.Paseman 12

Author Defined Fields

Page 13: Drupal 6 my experience

Web Site 2.0/Authoring/Drupal/Management

2/23/12 © W. G.Paseman 13

 Menus let me create a direct link to this piece of content from the menus

 Vocabularies put Taxonomy system “tags” on the content so I  Can sort content

 Can create Drilldowns

 Revisions let me record changes I made to the same piece of content over time.

 Authoring information lets me know which author added/changed the content.

 Publishing options let me control content visibility.  File attachments let me associate downloadable files with this

content  Comment settings let me control who (if anyone) can

comment on the content  URL path setting let me create “Frontpage-like” hierarchical

links to the content. E.g. this “node’s” name is   http://pacificseduction.com/node/62, however this

setting let’s me refer to it as  http://pacificseduction.com/Carnaza

Page 14: Drupal 6 my experience

Web Site 2.0/CMS in the cloud   Site Example: pacificseduction.com

  1.0 Multiple users browse a site containing a File System of hyperlinked documents.   2.0 Multiple User Types access a Site that frontends a Database of multiple Content types.

  Authoring   “Frontpage on Client” becomes “CMS In Cloud”   Permissions + Roles (later)

  Architecture   Client: Browser(Http(Url))   Transport: html+ css+ javascript+ img + …

  <div class="content"><p>Some Content<p></div>   Server: 3 Tier

  Tier 1: Web Server - Presentation   <div class="content"><p>Some Content<p></div>

  Tier 2: App Server - Logic   <div class="content"><?php print $content ?></div>   Implements CMS functionality in the cloud

  Tier 3: File System is replaced with DB Storage   Hierarchical Database becomes Relational

2/23/12 14 © W. G.Paseman

Page 15: Drupal 6 my experience

Web Site 2.0/Issues

2/23/12 © W. G.Paseman 15

  I need more than just Content, I need Engagement   I need to treat different types of users differently

 Change what people see depending on their "role".  Need to model users explicitly.

  Access Control – role/permissions

  I can increase engagement via some standard applications, E.g.  All Users can see content.  Registered Users can comment (comment module) on content.  Paid Users can blog (blog module) and access premium content.

  But I would like more behavior…. Add more cloud applications, E.g.  Products have price … and need a shopping cart!  Destinations have price … and need a reservation system.

Page 16: Drupal 6 my experience

W.G. Paseman

Drupal (6) Site Development

2/23/12 16 © W. G.Paseman

Page 17: Drupal 6 my experience

Agenda   Procedural (Amateur) vs. Declarative (Expert) Knowledge

  20101009_619_BarkadaStores   20110322_620_BarkadaMall_DNAsolutions   20110506_620_resortsmall   20110821_622_internationaltouristboards   20111120_622_pacificseduction

  Selecting a Host   Select/Modify your hosting Platform

  Choosing a Development Process   Manage How site changes over time.

  Deploy   Prep Host   From drupal.org download core or distribution (e.g. opendeals) and Patch locally   From drupal.org Select and Download, Modules   Upload, Configure Site   Enable, Configure Modules   Set Roles and Permissions

  Creating a UI   Select/Modify your “theme”

2/23/12 17 © W. G.Paseman

Page 18: Drupal 6 my experience

Selecting a Host/Options

2/23/12 © W. G.Paseman 18

  Localhost  Free, but you might get shut down if you open it up.

  Shared Server  order.1and1.com - $20/mo (Where I’ve been for a year)

  Dedicated Server  People seem to be migrating to to cloud instead

  Cloud Server  www.rackspace.com/cloud/cloud_hosting_products $150/mo   linode.com 1536 (barebones) - $60.00  AWS free usage tier - http://aws.amazon.com/free/

  www.coursera.org/saas

  Drupal optimized Hosts  www.acquia.com/cloud-pricing $169/mo <- support is $100 of this  Omega8.cc $64/mo <- trying Aegir out, but support is “early”

Page 19: Drupal 6 my experience

Selecting a Host/Issues

2/23/12 © W. G.Paseman 19

 Resources required  Compare http://drupal.org/requirements

  15 Meg disk, Apache 1.3, 2.x. , MySQL 5, php 5.3

 To phpinfo on your site choice e.g.   http://blossomdiagnostics.com/phpinfo.php   <?php phpinfo(); ?>

 Php.ini  Drupal 6

  register_globals = false   memory_limit = 36M

 Drupal 7   register_globals = false   memory_limit = 128M

Page 20: Drupal 6 my experience

Choosing a Development Process

2/23/12 © W. G.Paseman 20

  Drupal Structure: Their files, your files and a DB   Development Approach

 Local + Upload   My Local environment was different from Target

 Backup DB, Upload Files (onErr migrate oldfiles + Backup)  Utilize a drupal specific methodology (Aegir)

  Site(DB) -> PSV8.0 -> PSV8.0 -> PSV9.0   Platform -> Drupal6.22 -> Drupal6.24 -> Drupal6.24

  My Tools  On Host: phpMyAdmin  On Dev machine

  Browser + firebug   Cyberduck - ftp   SSH – crontab

  Drupal Update

Page 21: Drupal 6 my experience

Choosing a Development Process/Cyberduck

2/23/12 © W. G.Paseman 21

Page 22: Drupal 6 my experience

Deploy/Prep Host

2/23/12 © W. G.Paseman 22

  MySQL Administration  Database name : db396153918  User name : dbo396153918  Host name : db396153918.db.1and1.com  Port : 3306  Description : 20120222_624_pacificseduction  Version : MySQL5.0  Password: xxxxx 

  Domain Administration  pacificseduction.com -> /drupal/20120222_624_pacificseduction 

  Email Administration  *@pacificseduction.com -> [email protected]

  Create /drupal/keys directory if you are using SSL (must be peer)

Page 23: Drupal 6 my experience

Deploy/Download Core or Distribution, Patch

2/23/12 © W. G.Paseman 23

  Download/unzip distribution (or) Drupal core (6.24 or 7.13)  OpenDeals, commerce_kickstart

  Rename top directory {root} to mySQL Description String   (e.g. 20120222_624_pacificseduction)

  uncomment "RewriteBase /" in {root}/.htaccess  Needed for Clean URLs

  Create {root}/php.ini containing   register_globals = off  memory_limit = 96M

  Duplicate the {root}/sites/default/default.settings.php file to {root}/sites/default/settings.php.   “Get Info” and change settings.php permissions to “everyone Read and

write”

Page 24: Drupal 6 my experience

Deploy/Select, Download Modules

2/23/12 © W. G.Paseman 24

  Drupal adds behavior via distributions and Modules   14,900 modules – about 11,000 a year ago

  Token – Why this isn’t in core, I don’t know…   Cck – Add User Defined Fields

  Filefield – Uploadable Files   Imagefield, imagecache, imageapi – Uploadable images

  Views – Create Slideshows, Lists, Grids   google_analytics – Track your site via google.com/analytics/   Ubercart – product catalog + shopping cart

  Thickbox – lightbox for Products

  Add Modules to {root}/sites/all/modules   Follow per module README file instructions   E.g. ubercart_marketplace Place packingslip.itpl in {root}/sites/all/

modules/ubercart/uc_order/templates directory.

Page 25: Drupal 6 my experience

Deploy/Select, Download Modules  My Primary “Function” (Module) “How

To” Resource is “Using Drupal”  Example sites for job postings, product

reviews, wikis, photo galleries, stores, event management

 Addresses multilingual, workflow  Theming - not so much  Other Resources

 drupal.org  ubercart.org  youtube

2/23/12 25 © W. G.Paseman

Page 26: Drupal 6 my experience

Deploy/Download Modules

2/23/12 © W. G.Paseman 26

  token   cck

  imageapi   imagecache   imagefield   filefield

  Imce, ckeditor   admin_menu   vertical_tabs   advanced_help   views   views_slideshow

  captcha   menu_block   nice_menus   taxonomy_menu   Pathauto   date

 calendar   jquery_ui   jquery_update

  libraries   Devel*   Skinr   Drupad*

  Ubercart   thickbox   securepages   uc_coupon   ubercart_

marketplace   Gmap, location*

  embed_gmap   ad   advcontact   Chart   faq   Fb*   google_analytics

20111120_622_pacificseduction

Page 27: Drupal 6 my experience

Deploy/Upload, Configure Site

2/23/12 © W. G.Paseman 27

  All subsequent configuration is done from your url in your browser   Choose profile(done) Open Deals   Choose language(done) English (built-in)   Verify requirements(done)   Set up database(done)

  Database name : db396153918   User name : dbo396153918   Database password: xxxxxx   Host name : db396153918.db.1and1.com   Port : 3306

  Install profile(done) => Completed 95 of 95. Installed Open Deals module.   Configure site

  Site name: pacificseduction.com   Site e-mail address: webmaster pacificseduction.com   Username: webmaster   E-mail address: [email protected]   Default country: Philippines   Default time Zone: Asia/Hong Kong

Page 28: Drupal 6 my experience

Deploy/Enable Modules

2/23/12 © W. G.Paseman 28

 Modules are enabled  Modules use memory  Modules use CPU  Modules get updated

 This modifies your DB  Modules are configured

Page 29: Drupal 6 my experience

Upload, Enable, Configure Modules/Configure

2/23/12 © W. G.Paseman 29

Page 30: Drupal 6 my experience

Quiz

2/23/12 © W. G.Paseman 30

 How many lines of custom php code are in Pacific Seduction?

Page 31: Drupal 6 my experience

Deploy/Set Roles and Permissions

2/23/12 © W. G.Paseman 31

Page 32: Drupal 6 my experience

Creating a UI

2/23/12 © W. G.Paseman 32

 This is “A Whole Nother presentation”, but to start  /admin/build/themes/settings/global

 Upload logo image: gsmlogo2_80.jpg  Upload icon image: PacificSeduction_favicon.ico

 Note: need to clear cache to see new icon   admin/build/block

 move “Powered by Drupal” to “disabled”

Page 33: Drupal 6 my experience

Summary   My Experience   Drupal (6) Content Authoring

 Web Site 1.0 – Microsoft Frontpage   Edit Hierarchical Document on your computer

 Web Site 2.0 – Drupal   CMS (Content Management System) in the cloud

  Drupal (6) Site Development  Web Application –SAAS  Choosing a Development Process  Selecting a Host  Deploy  Creating a UI

2/23/12 33 © W. G.Paseman