yii php mvc framework presentation silicongulf.com
DESCRIPTION
Yii Framework is one of the fastest and easiest to learn PHP MVC frameworks. It has a great generator to help you build applications easier and faster. A course curriculum for Developing Web 2.0 Applications at SiliconGulf Campus - www.silicongulf.comTRANSCRIPT
Yii FrameworkCHRISTOPHER JOHN CUBOS
WEB DESIGN AND DEVELOPMENT MONTH (AUGUST 2011)COLLEGES & UNIVERSITIES DAVAO CITY PHILIPPINES
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Your First AnimationClicking your way through Adobe Edge
Who is Chris Cubos• Started programming at age 10 (1985)• Created his first website (1995)• The first web designer/developer in Mindanao• Been doing this for 26 years and still learning• Won the first web design competition in the Philippines
(1995) held in Cebu City• Developed his first CD-ROM application (1996)• Developed his first flash site (1995)
… forward to the present
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Tech Stuff• Languages: Q/BASIC/A, Pascal, C, C++,
Assembly, PHP, JavaScript, VBScript, ASP, AutoLISP, Lingo, ActionScripting, etc…
• PHP Frameworks: CodeIgniter, FuelPHP• CMS: Wordpress, Drupal, Joomla, Mambo, etc• Applications: Photoshop, Dreamweaver,
Illustrator, AfterEffects, Premiere, CS, etc…
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
1st Web Development Company• Won the Philippine Webby Awards for
Multimedia Category• Won Davao Web Design Competition in multiple
categories and the overall best web design• 1st Company to develop flash based applications• 1st Company to develop multimedia CD-ROMs• 1st Company to develop web portals• 2nd Company to develop a PH search engine• Won multiple awards in web design, logo design
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Yes the present• He currently devotes his time helping students
enhance their skills with the non-profit organization called the SiliconGulf Initiative
• He is also organizing large I.T. events in the Davao and currently organized the most number of I.T. events in a single month.
• Furthermore, he is currently developing the the first game-based training center in Mindanao
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Brewing• We are currently developing the first game-based
training center in Mindanao• Multiple mobile apps and games• Organizing multiple upcoming I.T. events
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
What is Yii Framework?• Yii is a high-performance PHP framework best
for developing Web 2.0 applications.• Yii helps Web developers build complex
applications and deliver them on-time.• Yii is pronounced as Yee or [ji:], and is an
acroynym for "Yes It Is!". This is often the accurate, and most concise response to inquires from those new to Yii
• Yii is the brainchild of Qiang Xue, who started the project on January 1, 2008
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
More about Yii• Yii is a free, open-source Web application development
framework written in PHP5 that promotes clean, DRY design and encourages rapid development.
• It works to streamline your application development and helps to ensure an extremely efficient, extensible, and maintainable end product.
• Being extremely performance optimized, Yii is a perfect choice for any sized project.
• It has been built with sophisticated, enterprise applications in mind.
• You have full control over the configuration.
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Basic Facts• 1 Year in the making• Model-View-Controller (MVC) design pattern• Based on Prado, RoR, Symfony, Joomla• AJAX-enabled widgets• Database Access Objects (DAO), Query Builder,
Active Record, DB Migration• Form input and validation• Skinning and theming• Authentication and authorization
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Quick Facts• Web services• Internationalization (I18N) and localization
(L10N)• Layered caching scheme• Error handling and logging• Security• Unit and functionality testing• Automatic code generation
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Fast Facts• Compliance to XHTML• Purely object-oriented• Friendly with third-party code• Detailed documentation• Extension library
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Why choose Yii• Generate applications fast with base examples
(blog, hangman, hello world, phone book)
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Getting Started: Downloadwww.Yiiframework.com
• Framework• Documentation• Demos
– Blog– Hangman– Hello World– Phone Book
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Requirements• PHP Version – 5.1• $_SERVER variable• Reflection extension• PCRE extension• APC extension
Check if your setup meet the requirements• /localhost/requirements/index.php
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Installing: Windows• Install Server• Download Yii• Install• Requirements• Code
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Recommended Tools• Adobe Dreamweaver• CodeLobster• E-texteditor• Komodo• Eclipse• Google Chrome• WAMP• Notepad++• Navicat
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Let’s Code .. Not!!!Excited, hehe
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Yiic and Gii• Yiic (command line tool) - create an application • Gii (powerful web based code generator) -
automate code creation for certain tasks
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Yiic.phpphp framework/yiic.php webapp myfirst
• This will create a skeleton Yii application under the directory _root/myfirst.
• The application has a directory structure that is needed by most Yii applications.
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Command Line
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Results
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
The Generated Codehttp://localhost/myfirst
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Configuring Gii\localhost\myfirst\protected\config\main.php
'modules'=>array(// uncomment the following to enable the Gii tool
'gii'=>array('class'=>'system.gii.GiiModule','password'=>'password','ipFilters'=>array('127.0.0.1','::1'),
),
),
http://localhost/myfirst/index.php?r=gii
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Gii the GUI Generator• Create
– Controllers– CRUD– Forms– Models– Modules
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
What’s next• Research• Compare• Develop Applications• Test• And do it all over again.
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
ThanksOops… There’s more
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Full year of IT EventsAugust 2011: Web Development MonthSeptember 2011: Mobile Application MonthOctober 2011: Animation MonthNovember 2011: Bloggers MonthDecember 2011: SEO MonthJanuary 2012: Technopreneurship MonthFebruary 2012: I.T. Education MonthMarch 2012: I.T. Career MonthApril 2012: Gaming MonthMay 2012: Graphic Design MonthJune 2012: Hacking and Network Security MonthJuly 2012: Software Development Month
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
August I.T. Events by PGOUniversity of Southeastern Philippines (USEP)Friday, August 12 · 9:00am - 11:30amhttp://www.facebook.com/event.php?eid=229646943743096 John Paul II College (JP2C)Saturday, August 13 · 9:00am - 4:00pmhttp://www.facebook.com/event.php?eid=220035684709122 University of Mindanao (UM)Wednesday, August 17 · 1:00pm - 5:00pmhttp://www.facebook.com/event.php?eid=245697658786703 University of Immaculate Conception (UIC)Saturday, August 20 · 1:00pm - 5:00pmhttp://www.facebook.com/event.php?eid=231713253532167
ACLCMonday, August 22 · 1:00pm - 4:00pmhttp://www.facebook.com/event.php?eid=231458190229578
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
August I.T. Events by PGOHoly Cross (HCDC)Tuesday, August 23 · 3:00pm - 6:00pmhttp://www.facebook.com/event.php?eid=253809011309471 InterCity College of Science and Technology (ICST)Wednesday, August 24 · 9:00pm - 11:00pmhttp://www.facebook.com/event.php?eid=225237414194879
AMA Computer CollegeThursday, August 25 · 9:30am - 1:00pmhttp://www.facebook.com/event.php?eid=138109472943706
STI CollegeFriday, August 26 · 1:00am - 4:00pmhttp://www.facebook.com/event.php?eid=124462760983852
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
CompetitionOn-the-spot Student Web Design CompetitionAugust 27, 2011http://www.facebook.com/event.php?eid=241281559236739
Entries can be found athttp://www.silicongulf.com/competitions/web_design
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Our Loving Supporters• The SiliconGulf Initiative• Davao IT• Adobe User Group• PHP Philippines• Developers, Entrepreneurs, Artists of Davao• SEO-Philippines• The IT School with no name yet• Philippine Global Outsourcing
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
ThanksTo all speakers, PHP framework developers, our
team at Philippine Global Outsourcing, students of all participating schools
To the Yii Framework Development Team for this wonderful piece of software.
Learn from the best www.silicongulf.com
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Contact2nd Floor Door #8 Andreliz Bldg#238 Araullo Extension8000 Davao City Philippinesphilippineoutsourcing@gmail.comwww.philippineglobaloutsourcing.com
+63 916 477 9322 (globe)+63 907 775 6544 (smart)+63 922 551 4009 (sun)+63 923 725 4512 (sun)+63 82 224 1040 (landline)
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
CopyrightThis reference material is exclusively distributed to the students of SiliconGulf Campus and should not be distributed, transmitted, or shared without the prior written consent of Christopher John Cubos http://www.philippineglobaloutsourcing.com/chriscubos ,SiliconGulf http://www.silicongulf.com/ or PhilippinesOutsourcing http://www.philippineglobaloutsourcing.com/ .
This class material should be discussed by a trained instructor from SiliconGulf to maximize the learning and understanding of the topic. Others belong to their respective copyright holders.
© Copyright 2011 SiliconGulf Campus and Christopher John Cubos. All Rights Reserved.
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
Disclaimer• Course technology and the author specifically
disclaim any and all other warranties, either express or implied, including warranties of merchantability, suitability to a particular task or purpose, or freedom from errors.
• Some states do not allow for exclusion of implied warranties or limitation of incidental or consequential damages, so these limitations might not apply to you.
Yii PHP MVC Framework Aug 2011 www.silicongulf.com
SiliconGulf CampusSiliconGulf Campus is one of the pioneers of game based learning system in the Philippines. Our goal is to combined complex theories with fun and excitement of playing games.
SiliconGulf Campus2nd Floor Door #8 Andreliz Bldg.#238 Araullo Extension8000 Davao City [email protected]+63 916 477 9322 (globe)+63 907 775 6544 (smart)+63 922 551 4009 (sun)+63 923 725 4512 (sun)+63 82 224 1040 (landline)
Yii PHP MVC Framework Aug 2011 www.silicongulf.com