国产av日韩一区二区三区精品,成人性爱视频在线观看,国产,欧美,日韩,一区,www.成色av久久成人,2222eeee成人天堂

? php教程 PHP開(kāi)發(fā) Zend ????? ????: MVC ?????? ???? ??? ??

Zend ????? ????: MVC ?????? ???? ??? ??

Jan 05, 2017 am 11:13 AM

? ????? Zend Framework ????? MVC ??????? Controller? ???? ??? ?????. ???? ? ??? ??? ??? ???. ??? ??? ??? ????.

??? MVC ???? Controller? ?? ??? ?? ???? ?????.

?? ?? ?:

root@coder-671T-M:/www/zf_demo1/application# tree.
├── Bootstrap.php
├── configs
│ └── application.ini
├── ????
│ ├── ErrorController.php
│ └── IndexController.php
├── ??
└── ??
├── ???
└── ????
├── ??
│ └── error.phtml
└── index
└── index.phtml

IndexController.php

<?php
class IndexController extends Zend_Controller_Action
{
  public function init()
  {
    /* Initialize action controller here */
  }
  public function indexAction()
  {
    // action body
  }
}

??:

1. ????? ????? /application/controllers ????? ?????. ?? ????.
?? ???? ??? ??? ??? ? ????.

Zend_Controller_Front::run(&#39;/path/to/app/controllers&#39;);

?? ?? ???? ??? ??? ??? ? ????.

// Set the default controller directory:
$front->setControllerDirectory(&#39;../application/controllers&#39;);
// Set several module directories at once:
$front->setControllerDirectory(array(
  &#39;default&#39; => &#39;../application/controllers&#39;,
  &#39;blog&#39;  => &#39;../modules/blog/controllers&#39;,
  &#39;news&#39;  => &#39;../modules/news/controllers&#39;,
));
// Add a &#39;foo&#39; module directory:
$front->addControllerDirectory(&#39;../modules/foo/controllers&#39;, &#39;foo&#39;);

????? ?? ????? ??? ? ????.

2. ???? ????? ?????
3. ????? Controller? ??? Zend_Controller_Action? ??????
4. ????? ? ??? ???? ???? ?? ???? ????. ???. Profit NewsListControlle
4. ?? ??? Controller.php? ????
5. ???? ???? init ???

public function init()
{
}

?? ??? ? ????.

? ?? PHP ?????? ???? ?? ??? ??? ??? ????.

Zend Framework ????? MVC ????? ???? ?? ?? ?? ??? ? ??? PHP ??? ????? ?????!

? ????? ??
? ?? ??? ????? ???? ??? ??????, ???? ?????? ????. ? ???? ?? ???? ?? ??? ?? ????. ???? ??? ???? ???? ??? ?? admin@php.cn?? ?????.

? AI ??

Undresser.AI Undress

Undresser.AI Undress

???? ?? ??? ??? ?? AI ?? ?

AI Clothes Remover

AI Clothes Remover

???? ?? ???? ??? AI ?????.

Video Face Swap

Video Face Swap

??? ??? AI ?? ?? ??? ???? ?? ???? ??? ?? ????!

???

??? ??

???++7.3.1

???++7.3.1

???? ?? ?? ?? ???

SublimeText3 ??? ??

SublimeText3 ??? ??

??? ??, ???? ?? ????.

???? 13.0.1 ???

???? 13.0.1 ???

??? PHP ?? ?? ??

???? CS6

???? CS6

??? ? ?? ??

SublimeText3 Mac ??

SublimeText3 Mac ??

? ??? ?? ?? ?????(SublimeText3)

???

??? ??

?? ????
1744
16
Cakephp ????
1596
56
??? ????
1537
28
PHP ????
1396
31
???