Hi,
Since your 'customer' sends you files with HTML and JS, I would suggest
you
create servlets that return JS data or functions. Each of the pages
could have
specific data associated with it that your servlet returns.
For example, if you were developing a Resturaunt menu page, and wanted
to
present a message at the top such as 'Specials today are ...' where
the '...' is replaced by the presentation of the specials offered you
could
do it with a combination of JS, HTML, and a servlet.
The page would use JS and loop through an array of specials. To get the
array,
the page would also reference a Servlet with:
<script scr="http://www.company.com/servlet/menu.Specials"></script>
and it would return something like:
var Specials = new Array()
function initSpecials()
{
Specials[1] = "Soup - $5.99"
Specials[2] = "Salad - $6.99"
}
The servlet does not return any HTML. Just this simple block of JS
code.
With this, the pages could use JS to display the data anyway that they
want to.
You could also require that the HTML pages reference a servlet that
contains
any other data that you use for tracking a user through a site.
The best part is that you will not have to learn any new languages or
techniques;
you could implement this today.
(The main page of www.Gallaware.com uses this technique.)
Tim Gallagher
www.gallaware.com
Satish Kamatkar wrote:
> maybe you want to use webmacro. http://www.webmacro.org
> -----Original Message-----
> From: A mailing list for discussion about Sun Microsystem's Java Servlet
> API Technology. [mailto:[EMAIL PROTECTED]]On Behalf Of bela
> Sent: Monday, September 20, 1999 2:31 PM
> To: [EMAIL PROTECTED]
> Subject: presentation and business logic
>
> Hi all,
>
> I am looking for a way to link presentation (HTML code), with business logic
> (Java Code).
> scenario:
> - Presentation is made by somebody else and arrives to me as a zip file with
> a bunch of html, js, image files inside.
> - I want to bother those files as less as possible. Otherwise for every
> change of the look (presentation) I have to add my changes again (e.g.
> hidden tags).
> - The look comes in a browsable way, so you can click on a link and you'll
> have the corresponding page.
> (all the values are hardcoded and those values I have to change)
>
> question:
> Assuming the scenario mentioned above, what is the best way to link
> presentation together with business logic in order to have the hardcoded
> values replaced and to be able to implement session tracking.
>
> ___________________________________________________________________________
> To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
> of the message "signoff SERVLET-INTEREST".
>
> Archives: http://archives.java.sun.com/archives/servlet-interest.html
> Resources: http://java.sun.com/products/servlet/external-resources.html
> LISTSERV Help: http://www.lsoft.com/manuals/user/user.html
>
> ___________________________________________________________________________
> To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
> of the message "signoff SERVLET-INTEREST".
>
> Archives: http://archives.java.sun.com/archives/servlet-interest.html
> Resources: http://java.sun.com/products/servlet/external-resources.html
> LISTSERV Help: http://www.lsoft.com/manuals/user/user.html
___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".
Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html