DC 1 - Hello World
As promised, a zip with the database version 01. It contains some basic elements for Notes and some vital elements to start building the web interface using QueryOpen agents.
The Notes elements
The Notes interface is very elementary and will only be used for creating and updating system documents (DbConfig, StyleSheets, Templates). It contains the following elements:
- About and Using the database
- Default Notes frameset
- Header and Outline pages
- A simple outline
- A simple 'All documents' view
The web elements
These are the basic components to start creating the web interface. So far, I've put in:
- A default stylesheet (page: 'css') to be used when no custom stylesheet is present
- A dummy navigator 'nLaunch' with a '$$NavigatorTemplateDefault' form as the 'homepage' of the database
- The 'home-wqopen' agent that renders the HTML for the homepage
- The LotusScript library '101-processing' which holds the 'WebSession' class shared by all the agents
- The LotusScript library '100-base' with the generic classes WebQuery and Stringbuffer (explained elsewhere on this blog)
How to use the database
- Unzip it and put it on a Domino server (minimal LND 7).
- Sign the database.
- Make sure you have manager access (internet: Editor) and Anonymous has reader access.
- Before first use, you have to open the database in the Notes client and click on the action "Open in Web Browser". This allows you to create the DbConfig document. Make sure you enter the correct URL of your server (default='http://localhost').
- After saving and closing the DbConfig document, click on the "Open in Web Browser" action again. This will open the application in a web browser (hopefully). If not: check what URL it tries to open and adjust the DbConfig document.
- Feel free to look at the code and figure out what exactly happens. You might want to browse through this blog: all the elements used are documented here.
Next
Now that we have our 'Hello World' in XHTML 1.0 Strict rendered by the Domino application, next post we might concentrate on making a simple web form to make some pages and make a simple web view to allow some navigation. Have I given the code for the WebForm class yet? I don't remember. This class allows to easily create valid XHTML 1.0 forms resulting in new or updated Notes documents. Anyway, next post will work on this.
Comments
02/06/2009 08:06:33 AM, Branimir Ćorluka
Hello Michel,
I have downloaded the db, and I am looking forward to go through this tutorial/guide/expirience with you.
After examining the db, I see you use OOP, one thought occured. Is it possible to expand this series of blog posts in a way that you write some architectural documentation regarding the db.
I know it is time consuming, but this would be great. UML diagrams, explanations of the code, show/explain us the design patterns that you use in your work regulary, I can see what the code does but what are the benefits of doing it that way.
It is great that you are doing this as a step by step guide, I hope we will have the oportunity to influence the project.
Greetings
06/02/2009 08:36:39, Michel Van der Meiren
Yes, I know. I am planning to add a pdf file with more detailed explanations. Problem indeed is finding the time...
02/06/2009 08:56:23 AM, Branimir Ćorluka
That would be nice. One question.
Is there a particular reason that you write your css on a page, and not as a file resource? Perhaps because you can edit it directly?
Greetings
06/02/2009 16:14:00, Michel Van der Meiren
Yes: on a page I can edit it directly, and I can add an expire date on it later so that it's cached by the browser. Works with JavaScript pages as well.
To add a comment, log in or register as new user. It's free and safe.