Building Twitter in Drupal

Jeff Eaton
Jeff EatonDigital Strategist
...in Drupal
Building Twitter in Drupal
What that means
What that means

 How we did it
What that means

  How we did it

Why you shouldn’t
So… what is Twitter?

• Streamlined info flow
• 140 character messages
• Just your friends
• ...And eighty jillion users
Twitter is growing.




Source: Jason Kottke (http://www.kottke.org/07/05/growth-of-twitter-vs-blogger)
Twitter is simple.
No, really. Simple.

 Public                User's               Friends'
Timeine                Page                  Posts



          Individual            Favorites   Update
             Post                  List      Form
What can users do?
What can users do?

• Post an update
What can users do?

• Post an update
• Follow a user
What can users do?

• Post an update
• Follow a user
• Bookmark a post
What can users do?

• Post an update
• Follow a user
• Bookmark a post
•…
What can users do?

• Post an update
• Follow a user
• Bookmark a post
•…
• Profit!
Why rebuild Twitter?




Image: Exploding Dog (http://www.explodingdog.com)
Why rebuild Twitter?
             • “Sandboxed” communication




Image: Exploding Dog (http://www.explodingdog.com)
Why rebuild Twitter?
             • “Sandboxed” communication
             • Integration into a larger site




Image: Exploding Dog (http://www.explodingdog.com)
Why rebuild Twitter?
             • “Sandboxed” communication
             • Integration into a larger site
             • The simplicity challenge




Image: Exploding Dog (http://www.explodingdog.com)
Why rebuild Twitter?
             • “Sandboxed” communication
             • Integration into a larger site
             • The simplicity challenge


             • Because it was there

Image: Exploding Dog (http://www.explodingdog.com)
What hath Drupal
   wrought?
What hath Drupal
       wrought?
• The actions (post, follow, favorite)
What hath Drupal
       wrought?
• The actions (post, follow, favorite)
• The views (timeline, friends, favorites)
What hath Drupal
       wrought?
• The actions (post, follow, favorite)
• The views (timeline, friends, favorites)
• The Simple™
What hath Drupal
       wrought?
• The actions (post, follow, favorite)
• The views (timeline, friends, favorites)
• The Simple™
• ...In 24 man-hours.
What hathn’t Drupal
    wrought?
What hathn’t Drupal
     wrought?
• Some layout details
What hathn’t Drupal
     wrought?
• Some layout details
• The SMS (SMS module)
What hathn’t Drupal
     wrought?
• Some layout details
• The SMS (SMS module)
• The API (Services module)
What hathn’t Drupal
     wrought?
• Some layout details
• The SMS (SMS module)
• The API (Services module)
• The Community (magic)
Building Twitter in Drupal
What did we just see?
What did we just see?
• One content type
What did we just see?
• One content type
• Two flags
What did we just see?
• One content type
• Two flags
• Four helper modules
What did we just see?
• One content type
• Two flags
• Four helper modules
• Five views
What did we just see?
• One content type
• Two flags
• Four helper modules
• Five views
• 200 lines of custom PHP
What did we just see?
• One content type
• Two flags
• Four helper modules
• Five views
• 200 lines of custom PHP
• One custom theme
The content type




• No title, no options: just a body field.
• Custom page.tpl.php in the theme
The sidebar

• Two blocks
• Defined by module
• 50-60 lines of PHP
• Faster, but brittle
Friends and favorites



• “Following” flag
• “Favorite” flag
• Works cleanly with Views
The update form




• Custom form in our module
• Simple validation
• Twitter’s Javascript
The listing pages




• Views module
• blittr.com/[list-style]/[username]
• Filtered by Flags
The look and feel!
The look and feel!

• Duplicates Twitter’s HTML
• Uses Twitter’s CSS
• Ignores the majority of Drupal’s data
• Seven replacement templates views fields)
  (page, page-node, block, node, views-table,
The other bits

• SMS Framework module
• Services module
• Mobile theme
• Personal CSS skins
• Privacy
The other bits

• SMS Framework module
• Services module
• Mobile theme
• Personal CSS skins
• Privacy
Yay!
This was a
Terrible Idea
Building Twitter in Drupal
Drupal is not
(just) a framework
Drupal’s mastery curve
   can be steep
Drupal is not
  an island
Drupal is
a powerful tool
Re-use the
techniques
Don’t rebuild Twitter...
Don’t rebuild Twitter...
  in any system!
1 of 57

Recommended

Web Design by
Web DesignWeb Design
Web Designnelsoniscool
325 views55 slides
HTML Design for Devices by
HTML Design for DevicesHTML Design for Devices
HTML Design for DevicesTerry Ryan
1.6K views75 slides
Making the Mobile Web Work by
Making the Mobile Web WorkMaking the Mobile Web Work
Making the Mobile Web WorkTerry Ryan
936 views37 slides
FITC - 2012-04-23 - Responsive Web Design by
FITC - 2012-04-23 - Responsive Web DesignFITC - 2012-04-23 - Responsive Web Design
FITC - 2012-04-23 - Responsive Web DesignFrédéric Harper
1.5K views54 slides
UCLA HACKU'11 by
UCLA HACKU'11UCLA HACKU'11
UCLA HACKU'11Gopal Venkatesan
669 views74 slides
Form API 3 by
Form API 3Form API 3
Form API 3Jeff Eaton
4.7K views26 slides

More Related Content

Similar to Building Twitter in Drupal

[Workshop] Analyzing Your Deliverables: Developing the Optimal Documentation ... by
[Workshop] Analyzing Your Deliverables: Developing the Optimal Documentation ...[Workshop] Analyzing Your Deliverables: Developing the Optimal Documentation ...
[Workshop] Analyzing Your Deliverables: Developing the Optimal Documentation ...Scott Abel
973 views56 slides
Analyzing Your Deliverables: Developing the Optimal Documentation Library by
Analyzing Your Deliverables: Developing the Optimal Documentation LibraryAnalyzing Your Deliverables: Developing the Optimal Documentation Library
Analyzing Your Deliverables: Developing the Optimal Documentation LibraryScott Abel
895 views56 slides
DjangoCon09: No! Bad Pony! by
DjangoCon09: No! Bad Pony!DjangoCon09: No! Bad Pony!
DjangoCon09: No! Bad Pony!Russell Keith-Magee
462 views48 slides
Webspam (English Version) by
Webspam (English Version)Webspam (English Version)
Webspam (English Version)Dirk Haun
14.1K views46 slides
Intro to Twitter for Business: Hubspot & Geek Girl Camp by
Intro to Twitter for Business: Hubspot & Geek Girl CampIntro to Twitter for Business: Hubspot & Geek Girl Camp
Intro to Twitter for Business: Hubspot & Geek Girl CampHubSpot
1.7K views50 slides
Twiggy - let's get our widget on! by
Twiggy - let's get our widget on!Twiggy - let's get our widget on!
Twiggy - let's get our widget on!Elliott Kember
485 views106 slides

Similar to Building Twitter in Drupal(20)

[Workshop] Analyzing Your Deliverables: Developing the Optimal Documentation ... by Scott Abel
[Workshop] Analyzing Your Deliverables: Developing the Optimal Documentation ...[Workshop] Analyzing Your Deliverables: Developing the Optimal Documentation ...
[Workshop] Analyzing Your Deliverables: Developing the Optimal Documentation ...
Scott Abel973 views
Analyzing Your Deliverables: Developing the Optimal Documentation Library by Scott Abel
Analyzing Your Deliverables: Developing the Optimal Documentation LibraryAnalyzing Your Deliverables: Developing the Optimal Documentation Library
Analyzing Your Deliverables: Developing the Optimal Documentation Library
Scott Abel895 views
Webspam (English Version) by Dirk Haun
Webspam (English Version)Webspam (English Version)
Webspam (English Version)
Dirk Haun14.1K views
Intro to Twitter for Business: Hubspot & Geek Girl Camp by HubSpot
Intro to Twitter for Business: Hubspot & Geek Girl CampIntro to Twitter for Business: Hubspot & Geek Girl Camp
Intro to Twitter for Business: Hubspot & Geek Girl Camp
HubSpot1.7K views
Twiggy - let's get our widget on! by Elliott Kember
Twiggy - let's get our widget on!Twiggy - let's get our widget on!
Twiggy - let's get our widget on!
Elliott Kember485 views
Blog Hands On Training by hyacinthus
Blog  Hands  On  TrainingBlog  Hands  On  Training
Blog Hands On Training
hyacinthus1.3K views
Extending the Blog Beyond the Blog by Dan Zarrella
Extending the Blog Beyond the BlogExtending the Blog Beyond the Blog
Extending the Blog Beyond the Blog
Dan Zarrella969 views
A For Apple, B For Blogging by Arun Basil Lal
A For Apple, B For BloggingA For Apple, B For Blogging
A For Apple, B For Blogging
Arun Basil Lal1.5K views
How To Integrate Social Media Into Your Wordpress Site by Convertiv
How To Integrate Social Media Into Your Wordpress SiteHow To Integrate Social Media Into Your Wordpress Site
How To Integrate Social Media Into Your Wordpress Site
Convertiv1.4K views
Beyond the Standards by Paul Bakaus
Beyond the StandardsBeyond the Standards
Beyond the Standards
Paul Bakaus464 views
Improving Drupal's Page Loading Performance by Wim Leers
Improving Drupal's Page Loading PerformanceImproving Drupal's Page Loading Performance
Improving Drupal's Page Loading Performance
Wim Leers2.7K views
David Esrati, The Blogzilla Report- Fact, Fiction Fear: The Monster of the In... by webcontent2007
David Esrati, The Blogzilla Report- Fact, Fiction Fear: The Monster of the In...David Esrati, The Blogzilla Report- Fact, Fiction Fear: The Monster of the In...
David Esrati, The Blogzilla Report- Fact, Fiction Fear: The Monster of the In...
webcontent2007568 views
Setting up the New Stuff: Planning & Implementing Library 2.0 by David King
Setting up the New Stuff: Planning & Implementing Library 2.0Setting up the New Stuff: Planning & Implementing Library 2.0
Setting up the New Stuff: Planning & Implementing Library 2.0
David King860 views
Deliverance: Plone theming without the learning curve from Plone Symposium Ea... by Jazkarta, Inc.
Deliverance: Plone theming without the learning curve from Plone Symposium Ea...Deliverance: Plone theming without the learning curve from Plone Symposium Ea...
Deliverance: Plone theming without the learning curve from Plone Symposium Ea...
Jazkarta, Inc.2.3K views

More from Jeff Eaton

This Is not a Place of Honor by
This Is not a Place of HonorThis Is not a Place of Honor
This Is not a Place of HonorJeff Eaton
561 views38 slides
An API Won't Fix Your Content Problem by
An API Won't Fix Your Content ProblemAn API Won't Fix Your Content Problem
An API Won't Fix Your Content ProblemJeff Eaton
565 views41 slides
Hello, {{FIRSTNAME}}, My Old Friend by
Hello, {{FIRSTNAME}}, My Old FriendHello, {{FIRSTNAME}}, My Old Friend
Hello, {{FIRSTNAME}}, My Old FriendJeff Eaton
751 views34 slides
Maps, Models, and Teams by
Maps, Models, and TeamsMaps, Models, and Teams
Maps, Models, and TeamsJeff Eaton
1.3K views58 slides
Collaborative Content Modeling by
Collaborative Content ModelingCollaborative Content Modeling
Collaborative Content ModelingJeff Eaton
892 views105 slides
Adventures in Drupal 8 by
Adventures in Drupal 8Adventures in Drupal 8
Adventures in Drupal 8Jeff Eaton
968 views43 slides

More from Jeff Eaton(20)

This Is not a Place of Honor by Jeff Eaton
This Is not a Place of HonorThis Is not a Place of Honor
This Is not a Place of Honor
Jeff Eaton561 views
An API Won't Fix Your Content Problem by Jeff Eaton
An API Won't Fix Your Content ProblemAn API Won't Fix Your Content Problem
An API Won't Fix Your Content Problem
Jeff Eaton565 views
Hello, {{FIRSTNAME}}, My Old Friend by Jeff Eaton
Hello, {{FIRSTNAME}}, My Old FriendHello, {{FIRSTNAME}}, My Old Friend
Hello, {{FIRSTNAME}}, My Old Friend
Jeff Eaton751 views
Maps, Models, and Teams by Jeff Eaton
Maps, Models, and TeamsMaps, Models, and Teams
Maps, Models, and Teams
Jeff Eaton1.3K views
Collaborative Content Modeling by Jeff Eaton
Collaborative Content ModelingCollaborative Content Modeling
Collaborative Content Modeling
Jeff Eaton892 views
Adventures in Drupal 8 by Jeff Eaton
Adventures in Drupal 8Adventures in Drupal 8
Adventures in Drupal 8
Jeff Eaton968 views
Recoupling by Jeff Eaton
RecouplingRecoupling
Recoupling
Jeff Eaton1.2K views
Modeling Rich Narrative Content by Jeff Eaton
Modeling Rich Narrative ContentModeling Rich Narrative Content
Modeling Rich Narrative Content
Jeff Eaton2.9K views
Battle for the Body Field (DrupalCon) by Jeff Eaton
Battle for the Body Field (DrupalCon)Battle for the Body Field (DrupalCon)
Battle for the Body Field (DrupalCon)
Jeff Eaton17.9K views
The Battle For The Body Field by Jeff Eaton
The Battle For The Body FieldThe Battle For The Body Field
The Battle For The Body Field
Jeff Eaton2.6K views
Workflow That Works Under Pressure by Jeff Eaton
Workflow That Works Under PressureWorkflow That Works Under Pressure
Workflow That Works Under Pressure
Jeff Eaton9.6K views
Planning Beyond the Page by Jeff Eaton
Planning Beyond the PagePlanning Beyond the Page
Planning Beyond the Page
Jeff Eaton9.9K views
Building Your Agency's Content Strategy Practice by Jeff Eaton
Building Your Agency's Content Strategy PracticeBuilding Your Agency's Content Strategy Practice
Building Your Agency's Content Strategy Practice
Jeff Eaton24.3K views
Deblobbing In The Real World by Jeff Eaton
Deblobbing In The Real WorldDeblobbing In The Real World
Deblobbing In The Real World
Jeff Eaton4.2K views
Prepare for the Mobilacalypse by Jeff Eaton
Prepare for the MobilacalypsePrepare for the Mobilacalypse
Prepare for the Mobilacalypse
Jeff Eaton1.6K views
Drupal in Action (CMS Expo 2011) by Jeff Eaton
Drupal in Action (CMS Expo 2011)Drupal in Action (CMS Expo 2011)
Drupal in Action (CMS Expo 2011)
Jeff Eaton1.5K views
Baby Got Backend (CMS Expo 2011) by Jeff Eaton
Baby Got Backend (CMS Expo 2011)Baby Got Backend (CMS Expo 2011)
Baby Got Backend (CMS Expo 2011)
Jeff Eaton1.3K views
The Platypus Problem by Jeff Eaton
The Platypus ProblemThe Platypus Problem
The Platypus Problem
Jeff Eaton3.8K views
Drupal in Action by Jeff Eaton
Drupal in ActionDrupal in Action
Drupal in Action
Jeff Eaton3.1K views
Architecture Is For Everyone by Jeff Eaton
Architecture Is For EveryoneArchitecture Is For Everyone
Architecture Is For Everyone
Jeff Eaton1.3K views

Recently uploaded

DRaaS using Snapshot copy and destination selection (DRaaS) - Alexandre Matti... by
DRaaS using Snapshot copy and destination selection (DRaaS) - Alexandre Matti...DRaaS using Snapshot copy and destination selection (DRaaS) - Alexandre Matti...
DRaaS using Snapshot copy and destination selection (DRaaS) - Alexandre Matti...ShapeBlue
139 views29 slides
2FA and OAuth2 in CloudStack - Andrija Panić - ShapeBlue by
2FA and OAuth2 in CloudStack - Andrija Panić - ShapeBlue2FA and OAuth2 in CloudStack - Andrija Panić - ShapeBlue
2FA and OAuth2 in CloudStack - Andrija Panić - ShapeBlueShapeBlue
147 views23 slides
Backroll, News and Demo - Pierre Charton, Matthias Dhellin, Ousmane Diarra - ... by
Backroll, News and Demo - Pierre Charton, Matthias Dhellin, Ousmane Diarra - ...Backroll, News and Demo - Pierre Charton, Matthias Dhellin, Ousmane Diarra - ...
Backroll, News and Demo - Pierre Charton, Matthias Dhellin, Ousmane Diarra - ...ShapeBlue
186 views15 slides
Webinar : Desperately Seeking Transformation - Part 2: Insights from leading... by
Webinar : Desperately Seeking Transformation - Part 2:  Insights from leading...Webinar : Desperately Seeking Transformation - Part 2:  Insights from leading...
Webinar : Desperately Seeking Transformation - Part 2: Insights from leading...The Digital Insurer
90 views52 slides
Transitioning from VMware vCloud to Apache CloudStack: A Path to Profitabilit... by
Transitioning from VMware vCloud to Apache CloudStack: A Path to Profitabilit...Transitioning from VMware vCloud to Apache CloudStack: A Path to Profitabilit...
Transitioning from VMware vCloud to Apache CloudStack: A Path to Profitabilit...ShapeBlue
159 views25 slides
Kyo - Functional Scala 2023.pdf by
Kyo - Functional Scala 2023.pdfKyo - Functional Scala 2023.pdf
Kyo - Functional Scala 2023.pdfFlavio W. Brasil
457 views92 slides

Recently uploaded(20)

DRaaS using Snapshot copy and destination selection (DRaaS) - Alexandre Matti... by ShapeBlue
DRaaS using Snapshot copy and destination selection (DRaaS) - Alexandre Matti...DRaaS using Snapshot copy and destination selection (DRaaS) - Alexandre Matti...
DRaaS using Snapshot copy and destination selection (DRaaS) - Alexandre Matti...
ShapeBlue139 views
2FA and OAuth2 in CloudStack - Andrija Panić - ShapeBlue by ShapeBlue
2FA and OAuth2 in CloudStack - Andrija Panić - ShapeBlue2FA and OAuth2 in CloudStack - Andrija Panić - ShapeBlue
2FA and OAuth2 in CloudStack - Andrija Panić - ShapeBlue
ShapeBlue147 views
Backroll, News and Demo - Pierre Charton, Matthias Dhellin, Ousmane Diarra - ... by ShapeBlue
Backroll, News and Demo - Pierre Charton, Matthias Dhellin, Ousmane Diarra - ...Backroll, News and Demo - Pierre Charton, Matthias Dhellin, Ousmane Diarra - ...
Backroll, News and Demo - Pierre Charton, Matthias Dhellin, Ousmane Diarra - ...
ShapeBlue186 views
Webinar : Desperately Seeking Transformation - Part 2: Insights from leading... by The Digital Insurer
Webinar : Desperately Seeking Transformation - Part 2:  Insights from leading...Webinar : Desperately Seeking Transformation - Part 2:  Insights from leading...
Webinar : Desperately Seeking Transformation - Part 2: Insights from leading...
Transitioning from VMware vCloud to Apache CloudStack: A Path to Profitabilit... by ShapeBlue
Transitioning from VMware vCloud to Apache CloudStack: A Path to Profitabilit...Transitioning from VMware vCloud to Apache CloudStack: A Path to Profitabilit...
Transitioning from VMware vCloud to Apache CloudStack: A Path to Profitabilit...
ShapeBlue159 views
CloudStack Object Storage - An Introduction - Vladimir Petrov - ShapeBlue by ShapeBlue
CloudStack Object Storage - An Introduction - Vladimir Petrov - ShapeBlueCloudStack Object Storage - An Introduction - Vladimir Petrov - ShapeBlue
CloudStack Object Storage - An Introduction - Vladimir Petrov - ShapeBlue
ShapeBlue138 views
Extending KVM Host HA for Non-NFS Storage - Alex Ivanov - StorPool by ShapeBlue
Extending KVM Host HA for Non-NFS Storage -  Alex Ivanov - StorPoolExtending KVM Host HA for Non-NFS Storage -  Alex Ivanov - StorPool
Extending KVM Host HA for Non-NFS Storage - Alex Ivanov - StorPool
ShapeBlue123 views
iSAQB Software Architecture Gathering 2023: How Process Orchestration Increas... by Bernd Ruecker
iSAQB Software Architecture Gathering 2023: How Process Orchestration Increas...iSAQB Software Architecture Gathering 2023: How Process Orchestration Increas...
iSAQB Software Architecture Gathering 2023: How Process Orchestration Increas...
Bernd Ruecker54 views
Backup and Disaster Recovery with CloudStack and StorPool - Workshop - Venko ... by ShapeBlue
Backup and Disaster Recovery with CloudStack and StorPool - Workshop - Venko ...Backup and Disaster Recovery with CloudStack and StorPool - Workshop - Venko ...
Backup and Disaster Recovery with CloudStack and StorPool - Workshop - Venko ...
ShapeBlue184 views
Business Analyst Series 2023 - Week 4 Session 8 by DianaGray10
Business Analyst Series 2023 -  Week 4 Session 8Business Analyst Series 2023 -  Week 4 Session 8
Business Analyst Series 2023 - Week 4 Session 8
DianaGray10123 views
CloudStack and GitOps at Enterprise Scale - Alex Dometrius, Rene Glover - AT&T by ShapeBlue
CloudStack and GitOps at Enterprise Scale - Alex Dometrius, Rene Glover - AT&TCloudStack and GitOps at Enterprise Scale - Alex Dometrius, Rene Glover - AT&T
CloudStack and GitOps at Enterprise Scale - Alex Dometrius, Rene Glover - AT&T
ShapeBlue152 views
VNF Integration and Support in CloudStack - Wei Zhou - ShapeBlue by ShapeBlue
VNF Integration and Support in CloudStack - Wei Zhou - ShapeBlueVNF Integration and Support in CloudStack - Wei Zhou - ShapeBlue
VNF Integration and Support in CloudStack - Wei Zhou - ShapeBlue
ShapeBlue203 views
Mitigating Common CloudStack Instance Deployment Failures - Jithin Raju - Sha... by ShapeBlue
Mitigating Common CloudStack Instance Deployment Failures - Jithin Raju - Sha...Mitigating Common CloudStack Instance Deployment Failures - Jithin Raju - Sha...
Mitigating Common CloudStack Instance Deployment Failures - Jithin Raju - Sha...
ShapeBlue180 views
Migrating VMware Infra to KVM Using CloudStack - Nicolas Vazquez - ShapeBlue by ShapeBlue
Migrating VMware Infra to KVM Using CloudStack - Nicolas Vazquez - ShapeBlueMigrating VMware Infra to KVM Using CloudStack - Nicolas Vazquez - ShapeBlue
Migrating VMware Infra to KVM Using CloudStack - Nicolas Vazquez - ShapeBlue
ShapeBlue218 views
Enabling DPU Hardware Accelerators in XCP-ng Cloud Platform Environment - And... by ShapeBlue
Enabling DPU Hardware Accelerators in XCP-ng Cloud Platform Environment - And...Enabling DPU Hardware Accelerators in XCP-ng Cloud Platform Environment - And...
Enabling DPU Hardware Accelerators in XCP-ng Cloud Platform Environment - And...
ShapeBlue106 views

Building Twitter in Drupal