Open a browser window and type http://localhost/caravan.html
You will be asked for a user name and password.
The default username is "admin" and password is "password"
The following menu will be displayed:
Caravan Enterprise Server
One stop solution for the web
All Rights Reserved
Configure Caravan Server ------disabled
Restart Server -----------------------disabled
Server Information -----------------disabled
Logout
Caravan Data Base Manager
Create A User
Edit
Change Password.
Select "change password" - other items will not work with the default password.
Once you have changed the password you can select other links and explore.
1. You can use create a user to create more users. The domain field in the user form defines the user's access rights. The domain for
admin is "admin".
2. Edit -- you can edit or create caravan scripts using the edit link.
3. Change password --- change the password. The link is "password.html"
4. Logout - to sign off.
Note : you may use "127.0.0.1" in case "localhost" is not defined.
Using the ftp server:
1. To use the ftp server of caravan , be sure the port defined in httpd.cnf (21) is available and caravan ftp server has started.
---- See if caravan has printed somthing like this on the console:
>FTP Server Started, listening on port: 21
2. Create a new user - use any domain - say "ftpuser". Go to the caravan database manager menu. select caravan database and users table. find the user you
have just created , and in the ftpDirectory field enter the home directory for this user's ftp access.
3. logout
4.open http://localhost/login.html
5. login with the new user name and default password "password"
6. if login was successful , open http://password.html
7. change password -- caravan does not allow ftp access unless the default password has been changed.
8. open an ftp client and access the caravan ftp port using the new username and password .
-- in an os/2 window type :
ftp localhost
>IBM TCP/IP for OS/2 - FTP Client ver 22:15:24 on Sep 22 1997
>Connected to localhost.
>220 caravan ftp server ready
>Name (localhost):
If you have done this successfully -- you can now access any database record , create users and modify fields in database tables.
You now have a new ftp server for os/2.
Getting Started with caravan script.
Most of the functionality of caravan will be evident only when the user learns the caravan scripting langauge.
Caravan script is embedded in html files which are to be located in the templates path defined in the httpd.cnf file.
To start with lets make a very simple dynamic html.
Caravan looks for *.html files in the "templates" directory and compiles them at startup. Please note that the extention is "html" not "htm".
Files which are in the documents path is served as static files. You can also create new templates online by the following method:
1. goto caravan menu
2. select edit
you will see that location is http://127.0.0.1/edit_tmpl.html
3.instead enter : " http://127.0.0.1/edit_tmpl.html?c=test.html" in the location and press enter;
test.html is the name of the new file you want to create. click on "create file"
---- please dont ask why !
4. You will be given a text box in which to enter the script:
type the following in the text box -- you can cut and paste
<html><body bgcolor=gray text=white>
<caravan>
time x
"<b>It is now</b>";" ";x(hour);":";x(minute);" on ";x(day);" ";x(month);" ";x(date);" ";x(year);"<br>"
</caravan>
</body></html>
Press the "Save File" button . You will see the name test.html in the list of templates you can edit from the template manager.
Now you have created a dynamic html document.
In the location of the browser, type :" http://localhost/test.html" and press enter:
Time will be displayed something like:
It is now 10:48 on Wed Nov 06 2002.
If you have come this far you know how to create and edit the caravan scripts!
Caravan script begins with the tag <caravan> and ends with the tag </caravan>
Caravan script can be anywhere in the html file.
Some variations of the above which produce essentially the same output.
------
1. Constant strings are either outside caravan script or are quoted.
Comments start after ";" with "//"; ";" or end of line is used to seperate caravan statements;
<caravan>
"<html><body bgcolor=gray text=white>\r\n"
time x ;// x is a variable of type time .
"<b>It is now</b>";" ";x(hour);":";x(minute);" on ";x(day);" ";x(month);" ";x(date);" ";x(year);"<br>" ;// month, date, day etc are properties of time
"</body></html>\r\n"
</caravan>
1. You can end and restart caravan script anywhere. The flow of logic is not affected!
Comments start after ";" with "//". Caravan language is not case sensitive.
<caravan>
"<html><body bgcolor=gray text=white>\r\n"
Time x ;// x is a (object) variable of type time .
"<b>It is now</b>";" ";x(hour);":";x(minute);</caravan>" on "<caravan>x(day);" ";x(month);" ";x(date);" ";x(year);"<br>" ;// month, date, day etc are properties of time
"</body></html>\r\n"
</caravan>
Time is a predefined caravan object type; x is an instance of time. It has the property of the current time;
Similarly caravan uses the following object types:
1.user object having the properties of the caravan user
2.table object having the properties of a caravan database table
3.file object of type file
4.folder represents a directory on the file system
5.var a user defined object having user defined properties
6.ftp an object used to access ftp servers
7.form an object similar to var but which can be posted to other http servers
8.mail an object representing mail which can be posted to smtp servers
9.queue a user defined event queue - which is linked to a
user created eventhandler, which is also a caravan script file in the templates directory.
10.time an object representing time.
etc.. etc..
In addition caravan has conditional statements, iteration, assignment, scheduling and security features.
I will be posting various utilities and updated files on www.response4u.com/os2.html. user.html is one
such utility which I am including with this package. In this concepts like iteration, user object and