[Zope] Global Variable
David Hassalevris
bluepaul at earthlink.net
Wed Aug 27 15:27:20 EDT 2003
If you do not forsee portibility as an issue than using folder properties is
surely cool for globals. Its just when you want to update data.fs and your
global is say a counter that things do not work out well.
I eventually had to move almost everything into a database. For example u
could have a table named globals. So ...
<dtml-in zSql_globals>
<dtml-var Company_name>
</dtml-in>
David
----- Original Message -----
From: "Mitch Pirtle" <mitchy at spacemonkeylabs.com>
To: <rpenatez at lattice.com.co>
Cc: <zope at zope.org>
Sent: Wednesday, August 27, 2003 2:06 PM
Subject: Re: [Zope] Global Variable
> On Wed, 2003-08-27 at 16:00, rpenatez at lattice.com.co wrote:
> > How can I assign a value to one of this variables??? How can I recover
the
> > variables values???
>
> No problemo! Follow these steps:
>
> 1) create folder called "test"
> 2) select "test" folder
> 3) click on "Properties" tab
> 4) at the bottom of the Properties screen, create a variable:
> Name: tequila
> Value: mezcal
> 5) create a document in the test folder called "test"
> 6) the content of that document should look like this:
>
> <dtml-var standard_html_header>
> <h2><dtml-var title_or_id></h2>
> <p>
> This is the <dtml-var id> Document.
> </p>
>
> <p>My favorite tequila is <dtml-var tequila>.</p>
> <dtml-var standard_html_footer>
>
>
> See how that works? Now, here is something important to remember - this
> variable is available to everything in that folder. If something is
> ABOVE that folder, then Zope cannot find that variable for you (it is
> not in the path).
>
> Let me know if you still have problems, ok?
>
> -- Mitch
>
>
> _______________________________________________
> Zope maillist - Zope at zope.org
> http://mail.zope.org/mailman/listinfo/zope
> ** No cross posts or HTML encoding! **
> (Related lists -
> http://mail.zope.org/mailman/listinfo/zope-announce
> http://mail.zope.org/mailman/listinfo/zope-dev )
More information about the Zope
mailing list