summaryrefslogtreecommitdiff
path: root/packages/fcl-web/examples/fptemplate/README.txt
blob: 5d2695c35bd211a4928e00706d02f83681715d16 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
FPTemplate examples
===================
These examples are demonstrating some uses of templates (with FPTemplate) when 
generating HTML pages by CGI/FCGI programs or Apache modules.

The main idea is to leave the web page designing and look&feel to the web page 
designers. Separating the web page design from the back-end CGI/FCGI/Apache 
application makes it possible to design, change or redesign a whole website 
without modifying a single line of code in the CGI/FCGI/Apache application. 
Back-end programmers and web page designers can work parallel easily, and 
neither side needs extensive knowledge of the other (does not hurt, just not 
necessary most of the time). 

With all this said, none of the examples are focusing on nice look and feel in 
their template designs, merely on demonstrating the functionality and use of 
templates, template-tags and template-tag-parameters with live applications.


Examples list:

1. /simpletemplate/*.*
The simplest template with one template tag in it to be replaced by the 
CGI/FCGI/Apache application when generating the response page -> {TagName1}
See README.txt

2. /tagparam/*.*
Demonstrating the set up and use of template tag parameter(s) 
-> {+DATETIME [-FORMAT=MM/DD hh:mm:ss-]+}

3. /listrecords/*.*
Demonstrates the use of a template tag with multiple template tag parameters 
to list multiple records, tables, lists, etc.
See README.txt

4. /fileupload/*.*
Demonstrates uploading file(s) to a web server with the help of a CGI/FCGI 
program or Apache module by using so called "multipart" html forms.
See README.txt
                                
5. /sessions/*.*
These examples demonstrate three different ways to maintain and use sessions 
when building web sites that need to carry over or store information to 
following web pages, differentiate between visitors, etc.

5.a. /sessions/cookiesessions-auto/*.*
See README.txt

5.b. /sessions/cookiesessions-login/*.*
See README.txt

5.c. /sessions/urlsessions-login/*.*
See README.txt

6. /embedtemplates/*.*
An example to show how to implement recursively embedded templates with fpweb.
See README.txt

Note: All of the examples have CGI, FCGI and Apache variations. The web 
modules (webmodule.pas, webmodule.lfm) and template html files for the paired 
CGI/FCGI/Apache applications are exactly the same, showing that from a 
developer standpoint there is not too much difference between writing CGI/FCGI 
programs or Apache modules with fcl-web (fpweb). The main differences are in 
the main project files (.lpr) and in the web server configurations.