Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Get started with Zend Framework
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Mohammad Shoriful Islam Ronju
February 26, 2012
Programming
3
180
Get started with Zend Framework
Kick start with zend framework in an easy way.
Mohammad Shoriful Islam Ronju
February 26, 2012
Tweet
Share
Other Decks in Programming
See All in Programming
CSC307 Lecture 02
javiergs
PRO
1
780
AI によるインシデント初動調査の自動化を行う AI インシデントコマンダーを作った話
azukiazusa1
1
730
副作用をどこに置くか問題:オブジェクト指向で整理する設計判断ツリー
koxya
1
610
フロントエンド開発の勘所 -複数事業を経験して見えた判断軸の違い-
heimusu
7
2.8k
AtCoder Conference 2025
shindannin
0
1.1k
AIと一緒にレガシーに向き合ってみた
nyafunta9858
0
230
Oxlint JS plugins
kazupon
1
920
AI & Enginnering
codelynx
0
110
Basic Architectures
denyspoltorak
0
670
AI巻き込み型コードレビューのススメ
nealle
1
210
Best-Practices-for-Cortex-Analyst-and-AI-Agent
ryotaroikeda
1
100
カスタマーサクセス業務を変革したヘルススコアの実現と学び
_hummer0724
0
700
Featured
See All Featured
Hiding What from Whom? A Critical Review of the History of Programming languages for Music
tomoyanonymous
2
420
DBのスキルで生き残る技術 - AI時代におけるテーブル設計の勘所
soudai
PRO
62
49k
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
38
2.7k
Practical Orchestrator
shlominoach
191
11k
Art, The Web, and Tiny UX
lynnandtonic
304
21k
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
31
3.1k
Code Reviewing Like a Champion
maltzj
527
40k
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
25
1.7k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
32
2.8k
Scaling GitHub
holman
464
140k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
49
9.9k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
47
7.9k
Transcript
Ge#ng Up & Running with Saidur Rahman
Bijon Shoriful Islam Ronju
Agenda • Overview • MVC • Components
• Environment setup • Your first Zend Framework project • Resources • QA
• Toolbox • Blueprint • Skeleton
What is framework ?
Why Zend Framework • Maintain by PHP Company • Open
Source • Flexible Architecture • ZF CerEficaEon • Partner with
Zend Components Zend_Session Zend_Validate Zend_Auth Zend_Acl
Zend web service v ZEND_FEED v ZEND_GDATA
Environment Setup • Requirements 1. PHP 5.x
2. Web server with mod_rewrite enabled
Environment Setup (ConEnued…) • Zend tool setup (Ubuntu way)
; include_path=${include_path} “:/path/to/libzend- framework-php” // uncomment in /etc/php5/conf.d/zend- framework.ini sudo apt-‐get install zend-‐framework
Environment Setup (ConEnued…) • Zend tool setup (Windows way)
Environment Setup (ConEnued…)
Environment Setup (ConEnued…)
Environment Setup (ConEnued…)
Environment Setup (ConEnued…)
Environment Setup (Continued…) • Zend tool setup verification zf show
version Zend Framework Version: 1.11.10
Your first Zend Framework project zf create project {project-‐name}
Create Virtual host <VirtualHost *:80> ServerName local.sitename.com DocumentRoot /var/www/zf-project/public
<Directory "/var/www/zf-project/public"> AllowOverride All </Directory> </VirtualHost>
Tada!
ConnecEng to database resources.db.adapter = "Pdo_Mysql” resources.db.params.host = ”HostName"
resources.db.params.username = ”UserName" resources.db.params.password = ”Password" resources.db.params.dbname = ”DbName"
Let’s have a CRUD operaEon Create Retrieve Update Delete
Controller zf create controller {name}
Controller <?php class AlbumController extends Zend_Controller_Action{ public function init(){
/* Initialize action controller here */ } public function indexAction(){ /* Your code goes here */ } }
Model zf create model {model-‐name}
Model <?php class Application_Model_Albums extends Zend_Db_Table_Abstract { protected $_name
= 'albums'; public function fName() { /* Your code goes here */ } }
Crud operaEon public function addAlbum($data) { $this->insert($data); } public
function updateAlbum($data, $where) { $this->update($data, $where); } public function deleteAlbum($where) { $this->delete($where); }
Zend Frameworks Gems J 1. Google 2. Amazon 3.
Flickr 4. Yahoo 5. More…. • Web services
Zend web service (flickr)
Zend web service (flickr) public function flickrAction(){ $flickr =
new Zend_Service_Flickr(’YourAPIKey'); $this->view->results = $flickr->tagSearch('worldcup’); }
Zend web service (flickr) <ul> <?php foreach ($this->results as
$result){ "$photo = $result->Square; ?> "<li><a href="<?php echo $photo->ClickUri ?>"> " "<img src="<?php echo $photo->uri ?>" alt="image"/> " </a> "</li> <?php } ?> </ul>
Resources • hPp://akrabat.com/zend-‐framework-‐tutorial/ • hPp://net.tutsplus.com/tutorials/php/zend-‐framework-‐from-‐scratch/ • hPp://goo.gl/fQLL6
QuesEons & Answers Any Question?