Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
ExpandTemplate() way of doing things
Message
De
20/10/2001 17:33:01
 
 
À
Tous
Information générale
Forum:
Visual FoxPro
Catégorie:
West Wind Web Connection
Titre:
ExpandTemplate() way of doing things
Divers
Thread ID:
00571366
Message ID:
00571366
Vues:
52
When calling ExpandTemplate(), this generates an header of its own. The problem is what if we need to add a cookie after we have called ExplandTemplate(). There is already an header. As far as I know, from all the threads I have read, it seems that the only way to create a cookie in WWC, is the create a header and write that header. Which means, we will end up with two headers. And, this is exactly what happens.

How to solve this problem?

Some will say that we should only call that function once and call it with the parameter of the header which could include the cookie. I don't believe in that. In several projects, I need to call that function at least two times per call before returning the content to the user. And, we are also adding some HTML on our own. And, then, after, the business logic might decide to add or not a cookie. That is a situation.

By default, once the process kicks in, we have access to Response, Request, Server and Session objects. But, where's the header. If there would be one, we could have access to it from anywhere and just add items to it. It seems that when we want to do it we have to create the object. If that would be the case, and if ExpandTemplate() would not deal with that, we would be ok. Having them independent would make things a lot easier.
Michel Fournier
Level Extreme Inc.
Designer, architect, owner of the Level Extreme Platform
Subscribe to the site at https://www.levelextreme.com/Home/DataEntry?Activator=55&NoStore=303
Subscription benefits https://www.levelextreme.com/Home/ViewPage?Activator=7&ID=52
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform