Home Accessibility Courses Twitter The Mouth Facebook Resources Site Map About Us Contact
For 2023 - we are now fully retired from IT training.
We have made many, many friends over 25 years of teaching about Python, Tcl, Perl, PHP, Lua, Java, C and C++ - and MySQL, Linux and Solaris/SunOS too. Our training notes are now very much out of date, but due to upward compatability most of our examples remain operational and even relevant ad you are welcome to make us if them "as seen" and at your own risk.

Lisa and I (Graham) now live in what was our training centre in Melksham - happy to meet with former delegates here - but do check ahead before coming round. We are far from inactive - rather, enjoying the times that we are retired but still healthy enough in mind and body to be active!

I am also active in many other area and still look after a lot of web sites - you can find an index ((here))

Well House Consultants
You are on the site of Well House Consultants who provide Open Source Training Courses and business hotel accommodation. You are welcome to browse and use our resources subject to our copyright statement and to add in links from your pages to ours.
Other subject areas - resources
Java Resources
Well House Manor Resources
Perl Resources
Python Resources
PHP Resources
Object Orientation and General topics
MySQL Resources
Linux / LAMP / Tomcat Resources
Well House Consultants Resources
Extras Resources
C and C++ Resources
Ruby Resources
Tcl/Tk Resources
Web and Intranet Resources
PHP module H302
MVC, 4 layer model and templating
Exercises, examples and other material relating to training module H302. This topic is presented on public courses Learning to program in PHP, PHP Programming, PHP Techniques, Intermediate PHP - weekend course / hobby / club / leisure users, PHP Programming, Learning to program in PHP

Related technical and longer articles
Keeping the PHP and the HTML apart

Articles and tips on this subjectupdated
4314PHP training - refreshed modern course, backed up by years of practical experience
Our PHP course agendas were updated recently, and last week we ran our first series of courses in the new way. Learning to program in PHP started on Monday for delegate who are new to programming (or rusty) and PHP Programing for experienced programmers converting to PHP staretd on Tuesday. Programming ...
4114Teaching CodeIgniter - MVC and PHP
CodeIgniter is becoming a very popular web Framework for PHP, and I can see why. Another private session today with a customer who wanted to go through the whole MVC thing - well experienced in web and PHP, and objects too... just needing to get into Frameworks to write code that's more re-usable and ...
4066MVC and Frameworks - a lesson from first principles in PHP
PHP is a nice, easy entry level embedded tagging system - an "HTML++" language in which programmers and web site developers can drop elements of code into a web page and perform simple and straigtforward tasks very quickly. But the downside of that is that the resultant file very quickly becomes a confusing ...
3956Zend / layout of MVC and other files in an example application (PHP)
Under the Zend Framework, all URLs get mapped to mvc.php which in turn acts as the router. There are separate directories / folders for code in each of the • model • view • controller and a wide variety of configuration files and libraries used too. Here's a diagram showing the layout ...
3539Separating program and artwork in PHP - easier maintainance, and better for the user
I can code reasonably well. But my graphic design sucks. And both skills are needed for even a simple web data entry form, or a small application. Using the PHP "bull at a gate" approach, both business logic (the code) and look and feel (the graphic art stuff) can be written into a single file, but ...
3454Your PHP website - how to factor and refactor to reduce growing pains
As your project grows ... what do you change? In an ideal world, you would know exactly what you were coding before you started, and write the full job to spec to last for many years. This isn't an ideal world, though. Our web site has changed over the years - we now have "version 8" (See [here] to ...
2221Adding a newsfeed for your users to a multipage PHP application
As I wrote it, I realised this was turning into rather a long article, but never mind. It shows the major new components added to a "4 layer model" application I was working on the weekend before last to add in a newsfeed for logged in users to which they can contribute, together with a headlines-only ...
2199Improving the structure of your early PHP programs
When you first coded in PHP, you probably wrote a different script to handle each form in a series - it's the natural way when you're early in the learning process, but it can lead to repeated code that's hard to follow, and some really horrid complicated conditionals. On Saturday and Sunday, I demonstrated ...
2174Application design in PHP - multiple step processes
When you're putting together a multiple step process in PHP (and that could be anything from a forum to an ordering system), you should bare in mind that each of the program elements will be the 'intermediate' step that takes you from one display to the next ... and that you can't be sure when page "X" ...
1766Diagrams to show you how - Tomcat, Java, PHP
I like to work with a flipchart occasionally, and I have been doing so quite a bit this week, which is a week that I'm giving a wide ranging web server deployment course under Linux, covering both LAMP / PHP technologies, and Tomcat / Java too. Why do I like using a flipchart? Because it encourages ...
1716Larger applications in PHP
I've just finished a two day PHP techniques course - a subject that's tremendous fun to present, and a huge benefit to the delegates, as PHP programs can be written with great beauty, maintainability and expandability (like a Picasso) or they can be an unmaintainable mess (making the dog's dinner look ...
1634Kiss and Book
The headline on our story reads "We've got a New Online Booking System for our Open Source courses" ... but there's a story behind that headline. We pride ourselves in our flexibility - the ability to treat each customer as an individual and offer him a solution to meet his or her needs. And that means ...
Examples from our training material
business.inc   Business Logic
george.htp   View - for view / program separation
george.php   Simple separation of view from program
mpa.php   First shell for multipage application
mpb.php   Stepping through and validating over multiple pages
mpc.php   Session based multiple page application Mk 1
mpd.php   Session based multiple page application Mk 2
mpe.php   Session based multiple page application Mk 3
multiply.php   Separting look and feel from business logic - business logic
mvc_control.php   Control - All elements in one piece of code
mvc_principles.php   Model, View, Controller, Components, Framework and Helpers - single file
mvc_split.php   Controller for Model, View, Controller demo
needed.inc   Sample included file
product.txt   Product listing
shoptop.php   Top level
simsess.php   Session demo / single included file
stages.finish0.inc   initialise for new visitor
stages.finish1.inc   validate email, name and department
stages.finish2.inc   Read and record an incident record
stages.htp   Multiple Stage Application
stages.php   Muliple page, session based application
stages.prepare1.inc   prepare for phase 1
stages.prepare2.inc   prepare for phase 2
stages.prepare3.inc   prepare phase 3 - no form, just an onward link
stages.webhelpers.inc   Web helpers for stage.php demo
t2.xxx   Look and feel (business logic elsewhere)
template.txt   template file
web.inc   Web Helpers
z_framework.php   Framework and bootstrap for MVC demo
z_helpers.php   Helpers for MVC demo
z_model.php   Model for MVC demo
z_view.htp   View (Template) for MVC demo
Background information
Some modules are available for download as a sample of our material or under an Open Training Notes License for free download from [here].
Topics covered in this module
How to design and structure your application.
Model - View - Controller.
Top level, business logic, web helpers and template.
Objects - how and when to use them.
Handling the look and feel with DreamWeaver.
A little on database design.
Configuration files.
Shopping cart applications.
Complete learning
If you are looking for a complete course and not just a information on a single subject, visit our Listing and schedule page.

Well House Consultants specialise in training courses in Ruby, Lua, Python, Perl, PHP, and MySQL. We run Private Courses throughout the UK (and beyond for longer courses), and Public Courses at our training centre in Melksham, Wiltshire, England. It's surprisingly cost effective to come on our public courses - even if you live in a different country or continent to us.

We have a technical library of over 700 books on the subjects on which we teach. These books are available for reference at our training centre.

You can Add a comment or ranking to this page

© WELL HOUSE CONSULTANTS LTD., 2023: 48 Spa Road • Melksham, Wiltshire • United Kingdom • SN12 7NY
PH: 01144 1225 708225 • EMAIL: info@wellho.net • WEB: http://www.wellho.net • SKYPE: wellho

PAGE: http://www.wellho.net/resources/H302.html • PAGE BUILT: Sun Oct 11 14:50:09 2020 • BUILD SYSTEM: JelliaJamb