Templates are pure html files
usually located in the directory "data/templates". The system
uses specific variables or place holders inside these templates or html
files to its insert the output.
Language Variables:
Because the system is multi language capable, the program uses a
language variables inside the templates instead of using the actual text.
Each language variable refers to some text in the language files.
The language variables are inserted inside
the templates between "[[" and "]]" as follows:
[[language_variable_name]]
At the program run time, the system will
replace the language variables by its text values. This way, the same
template is used to display any number of languages.
Language variables and text are kept
inside the language files. Each language has its own directory under the
"data/language" directory. below is few lines of a langue file
shows how these files are build.
create_account~==~Create Account
edit_profile~==~Edit Profile
registration~==~Registration
search_home_bar~==~Main
browse_categories~==~Categories
account_manager~==~Manage Account
Each line is a language variable and its
value separated by "~==~" and must be on one single line. These
files can easily edited from the administration center or using any text
editor. Language files has the extension ".pm" and must be
edited and transferred in ASCII mode not binary mode.
Classes:
Since the system is template driven, the program uses a special plug ins
or place holders inside the templates.
The general format for the classes is:
<!--CLASS::Class_Name-->
Where "Class_Name" is a
unique name for each class. Some classes are general and can be used
inside any template, like the "Header" class. Some classes are
specific to certain functions and therefore only available for specific
templates.
At the program run time, the system will
replace the "<!--CLASS::Class_Name-->" by code generated
for this specific function name. This way the program can place the code
generated inside the templates anywhere you place these classes. This
allows you full control over the program output and customization.
|