Table of Contents

Files Layout

With Mivec’s distribution package, we will have the following layout of files:

Based on the deployment environment, such as server ownership, permissions on directories on the server, you may have different arrangements on placing the libraries of Mivec Framework, (optionally) log4php and Smarty, and the web application’s Action, view templates and its dependencies.

Combined Deployment

This deployment scheme is usually for cases which you are not owning the server, and it is also the default deployment scheme for Mivec Framework + example application’s distribution.

It is recommended, however, you can use .htaccess to protect the directories where Mivec Framework and your web application’s dependencies (Actions, view templates, message resources, and other PHP scripts) are placed. Otherwise, if you are working on a UNIX server, you may try using chmod to block client from accessing Mivec Framework or your web application’s directory directly.

Below is an example, which is also the layout for Mivec Framework + example application’s distribution.

Separated Deployment

This deployment scheme is the recommended approach; but it requires that you have complete control of the server.

The idea is to put the whole Mivec Framework away from the web server’s htdocs directory. Instead, we put it at somewhere the web server can use “require_once” statement to get the dependencies wuth Mivec Framework.

Below is an example of such deployment scheme. Mivec Framework’s library is placed under /usr/share/lib; and the web application itself is still placed under the web server’s web root (in this case, /srv/www/htdocs).

However, you must change the following statement at MivecServlet.php, which is at the beginning of the file (after the license statement) to declare the location of the Mivec Framework.

define ("MIVEC_HOME", "usr/share/lib/mivec");

You don’t need to add a trailing slash, however.


« Prev: System Requirements Next: Initial Environment Test »

 
  devguide/file_layout.txt · Last modified: 2005/02/15 03:27
 
Recent changes RSS feed Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki

SourceForge.net Logo