OpenCart 1.x uses an
MVC(+L) style framework. The
+L isn't part of the framework persay, but it
is important to understand the localization and how text for different languages is used:
First off, OpenCart's root directory looks something like this:
catalog - the catalog directory path stores all the code on the front end of your site
admin - the admin directory path is all the code on the front end of your site. This is completely separate from the catalog area and can even be stored on a different host if you have a high-security persona.
image - the image directory path is where all the product images are stored
download - the download directory path is where all the downloads are stored
system - the system path has all the common libraries and engine code. Both admin and catalog use this folder, so if storing admin on another server, you will also need to copy the system folder there.
In the catalog and admin directories, a common tree based on the MVC(+L) architecture is formed:
Model - Database layer - All calls to the database are done here, referenced from the controller
View - Template display - This is where the HTML and designing is done
Controller - Main controlling code base - This is where the functional code logic is processed
Language - Localization/Language - This is where you set which constants translate to text for things like heading titles, static links and text, etc.
So for example, for the product page on the frontend, there are 4 main files:
M: \catalog\model\catalog\product.php
V: \catalog\view\theme\default\template\product\produ ct.tpl
C: \catalog\controller\product\product.php
L: \catalog\language\english\product\product.php
Similarly, on the admin side, to set those fields, there are 4 main files as well:
M: \admin\model\catalog\product.php
V: \admin\view\template\catalog\product_form.tpl
C: \admin\controller\catalog\product.php
L: \admin\language\english\catalog\product.php