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
180
3
Share
Get started with Zend Framework
Kick start with zend framework in an easy way.
Mohammad Shoriful Islam Ronju
February 26, 2012
Other Decks in Programming
See All in Programming
JavaDoc 再入門
nagise
0
220
inferと仲良くなる10分間
ryokatsuse
1
280
tsserverとは何だったのか、これからどうなるのか
nowaki28
1
420
横断組織出身のQAEがインプロセスQAEでつまずいたこと・活かせたこと
ty89
0
470
運用エージェントは "作る" から "育てる" へ - 記憶と自己進化の3層設計パターン / self-evolving-agents-three-layer-agent-design
gawa
12
3.3k
Inside Stream API
skrb
1
410
Oxlintのカスタムルールの現況
syumai
5
900
3Dシーンの圧縮
fadis
1
530
柔軟なPDFレイアウトエディタを支える型システム設計 — Discriminated UnionとConditional Typeの実践
minako__ph
4
1.2k
net-httpのHTTP/2対応について
naruse
0
370
1人1案件のプロダクトエンジニア時代に、"プロセス監督"としてチャレンジしたこと
non0113
0
350
Zod v4 Codec でスキーマに型変換を埋め込む REST API 設計 #TSKaigi2026
ryutaro_yako
0
170
Featured
See All Featured
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
659
62k
Marketing Yourself as an Engineer | Alaka | Gurzu
gurzu
0
210
Organizational Design Perspectives: An Ontology of Organizational Design Elements
kimpetersen
PRO
1
710
Navigating Team Friction
lara
192
16k
職位にかかわらず全員がリーダーシップを発揮するチーム作り / Building a team where everyone can demonstrate leadership regardless of position
madoxten
62
54k
Navigating the moral maze — ethical principles for Al-driven product design
skipperchong
2
370
Deep Space Network (abreviated)
tonyrice
0
160
SEO for Brand Visibility & Recognition
aleyda
0
4.6k
SEO Brein meetup: CTRL+C is not how to scale international SEO
lindahogenes
1
2.7k
Fashionably flexible responsive web design (full day workshop)
malarkey
408
66k
Making Projects Easy
brettharned
120
6.7k
BBQ
matthewcrist
89
10k
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?