Setting up an MVC structure with the Zend Framework – part 1

Hi,

I just released a new video on setting up an MVC structure with the Zend Framework. This video is a little more basic than the previous Zend videos … I had to twist Jon’s arm a little.

zend framework logo

Anyway, let us know what you think and should you have any suggestions or request, please feel free to comment.

Running time: 12+ minutes
Part 1 of 2.

Thanks,

Stefan Mischook

www.killerphp.com
www.killersites.com


This entry was posted on Monday, March 24th, 2008 at 3:21 pm and is filed under Object Oriented PHP, PHP Videos, Zend-Framework. You can follow any responses to this entry through the RSS 2.0 feed. Both comments and pings are currently closed.

10 Responses to “Setting up an MVC structure with the Zend Framework – part 1”

  1. [...] Visit Original: Setting up an MVC structure with the Zend Framework – part 1 [...]

  2. acido69 says:

    trackback: “Un vídeo bastante ilustrativo para empezar a trabajar en MVC con ZF; está en ingles pero es bastante fácil de entender.”

    http://cuatroxl.wordpress.com/2008/03/25/empezando-en-la-estructura-mvc-con-zend_framework-i-video-tutorial/

  3. [...] Stefan Mischook has just posted a new video in his set of PHP-related presentations – part one of a look at setting up the MVC structure in a Zend Framework application. This video is a little more basic than the previous Zend videos. [...]

  4. Andy says:

    I found your tutorial on ZF very helpful for my 1st forray into this new framework.

    The one part I struggled with is where you set up your Virtual hosts with MAMP. You had a custom httpd.conf file but I tried to replicate your your syntax with the help of the apache manual on setting up virtual hosts with no luck.

    Is there any possibility of you doing a screen cast or tutorial on how you set up your MAMP virtual hosts please. I did a google search and there is a lot of people having similar problems and the MAMP forum isn’t very helpful :(

    keep up the good work, thanks.

  5. @Andy:

    Thanks for the feedback. Doing a MAMP video sounds like a great idea. I’ll put something together in the coming weeks.

  6. david says:

    @Andy I struggled with this to. I use linux so what I eventually ended up doing was making a new folder called virtualhost in my httpd directory or in the parent directory of where your httpd.conf file is i.e.
    ->httpd “folder”
    ->->conf “folder”
    ->->->httpd.conf “file”
    ->->virtualhost “folder”
    ->->->v.hosts.conf “file”

    And after backing up my httpd.conf file to httpd.conf.backup I went down to section 3 of my httpd.conf file and cut the whole section out and put it in my v.host.conf file and then where section 3 was I ended up putting include virtualhosts/*.conf
    Now depending on your directory root of your virtualhost, if it is above your default directory root you might have to add

    Options FollowSymLinks
    AllowOveride ALL

    The “*” means any folder I drop in sites that has a public_html folder will read .htacces files with the AllowOveride set to All. The Options can be overridden by the virtual host configuration file.
    In my host file I added the 127.0.0.1 “whatever”
    and in the v.host.conf file I have this setup
    NameVirtualHost 127.0.0.1

    #
    # VirtualHost example:
    # Almost any Apache directive may go into a VirtualHost container.
    # The first VirtualHost section is used for all requests that do not
    # match a ServerName or ServerAlias in any block.
    #

    DocumentRoot “/var/www/html”
    ServerName localhost

    ServerAdmin admin@zendtest
    DocumentRoot “/var/www/sites/zendtest/public_html”
    ServerName zendtest
    ErrorLog /var/www/sites/zendtest/logs/error_log
    CustomLog /var/www/sites/zendtest/logs/access.log common

    DocumentRoot “/var/www/sites/zendtest/tests”
    ServerName zendtest.test

  7. david says:

    stripped my <’s and >’s
    so it would be
    <Directory “var/www/sites/*/” >
    Options FollowSymLinks
    AllowOveride ALL
    <\Directory >
    and the v.hosts are
    <VirtualHost 127.0.0.1 >
    DocumentRoot “/var/www/html”
    ServerName localhost
    <\VirtualHost >
    <VirtualHost 127.0.0.1 >
    ServerAdmin admin@zendtest
    DocumentRoot “/var/www/sites/zendtest/public_html”
    ServerName zendtest
    ErrorLog /var/www/sites/zendtest/logs/error_log
    CustomLog /var/www/sites/zendtest/logs/access.log common
    <\VirtualHost >
    <VirtualHost 127.0.0.1 >
    DocumentRoot “/var/www/sites/zendtest/tests”
    ServerName zendtest.test
    <\VirtualHost >

  8. david says:

    Options FollowSymLinks
    AllowOveride ALL

    my bad

  9. david says:

    <Directory “var/www/sites/*/public_html” >
    Options FollowSymLinks
    AllowOveride ALL
    <\Directory >
    sorry again stefan

Created By Stefan Mischook  |  Top of page  go to top of page