17
Lets talk about Craft! Presented by Jason McCallister

San Diego PHP Craft CMS

Embed Size (px)

DESCRIPTION

My presentation at San Diego PHP meetup group for April 2014.

Citation preview

Page 1: San Diego PHP Craft CMS

Lets talk about Craft!

Presented by Jason McCallister

Page 2: San Diego PHP Craft CMS

No, no - not that kind of Craft….

this kind…

Page 3: San Diego PHP Craft CMS

intro• Developed by Pixel & Tonic (pixelandtonic.com

)

• Makers of popular ExpressionEngine add-ons Playa, Matrix and more.

• Version 2.0 was released on April 1st

• Built on Yii (http://www.yiiframework.com/)

• Twig Template Engine (http://twig.sensiolabs.org/)

Page 4: San Diego PHP Craft CMS

a few features• One-click updating

• Live Preview

• Matrix

• Responsive Control Panel

• Sections and Channels

• Entry types

Page 5: San Diego PHP Craft CMS

different..• Built completely around your content -

assumes zero about your website and content (no required files or templates - or even fields!)

• Support on Google Plus and via email directly from the developers

• Element Types

Page 6: San Diego PHP Craft CMS

element types

“File systems manages files. iPhoto manages photos. iTunes manages media. Blogging systems manage entries. And content management systems manage… “content”. But what is “content”? Historically it has meant “entries…”

http://pixelandtonic.com/blog/craft-element-types

Page 7: San Diego PHP Craft CMS

element types“While other content management systems are busy managing entries, Craft manages elements. Everything in Craft – your site’s users, assets, categories, tags, globals, even Matrix blocks, and of course, entries – they’re all elements. That’s why everything is so consistent in Craft. It’s not that entries and users both individually have custom field support, it’s that they share the same system-wide custom field support that’s available to all elements. Same with relations, and a slew of other things.”

http://pixelandtonic.com/blog/craft-element-types

Page 8: San Diego PHP Craft CMS

element types“…People expect more and more out of their websites. Even “simple” content-only sites aren’t so simple anymore. It’s not just about entries having custom fields; it’s about custom fields everywhere – on assets, users, categories, tags, even custom fields within custom fields (a la Matrix). We’ve been at the forefront of the custom field craze at P&T – our FieldFrame for ExpressionEngine ignited it…”

http://www.producthunt.co/posts/2526

Page 9: San Diego PHP Craft CMS

craft/config/db.php’server' => 'localhost',

'user' => ‘awesome_squirrel',

'password' => ‘Sup3rSEcritP@$$‘,

'database' => 'myAwesomeCoolDB',

/** only required configuration for installation */

Page 10: San Diego PHP Craft CMS

craft/config/general.php

‘omitScriptNameInUrls' => true,

'cpTrigger' => ‘the-cloud’,

'siteUrl' => ‘http://domainname.com‘,

'fileSystemPath' => ‘/path/to/folder’,

'devMode' => true,

/** more http://buildwithcraft.com/docs/config-settings */

Page 11: San Diego PHP Craft CMS

multi-env general.php

return array(

’*' => array(

'omitScriptNameInUrls' => true,

'cpTrigger' => ‘secretAgentMan'

),

'mydevwebsite.local' => array(

'devMode' => true,

'environmentVariables' => array(

'siteUrl' => 'http://mydevwebsite.local',

'fileSystemPath' => ‘/path/to/mydevwebsite.local’

)

),

Page 12: San Diego PHP Craft CMS

multi-env db.phpreturn array(

'*' => array(

'tablePrefix' => 'prefix',

),

‘domain.local' => array(

'server' => 'localhost',

'user' => 'user',

'password' => 'password',

'database' => 'dbnamegoeshere',

),

‘domain.com' => array(

'server' => getenv('DBHOST'),

'user' => getenv('DBUSER'),

'password' => getenv('DBPASS'),

'database' => getenv('DBNAME'),

)),

Page 13: San Diego PHP Craft CMS

twiggy, twig, twig…

Page 14: San Diego PHP Craft CMS

OMG UNICORNS!“..its like a magical walk down candy lane with

unicorns…”

Page 15: San Diego PHP Craft CMS

resourcesStraight Up Craft

http://straightupcraft.com

Craft Cookbook

http://craftcookbook.net/

Page 16: San Diego PHP Craft CMS

exit;the boring part is now over….

Page 17: San Diego PHP Craft CMS

thank you!

Jason McCallister

http://themccallister.com

or

@theMcCallister