[Zope] random content generation

Tony.McDonald@newcastle.ac.uk Tony.McDonald@newcastle.ac.uk
Wed, 4 Aug 1999 22:58:10 +0100 (BST)


> 
> Hi,
> 
> I followed the instructions for random content generation exactly, but I
> keep getting a "System Unavailable" error message now and then.  I thought
> the problem was that I left empty lines in the "lines" properties I created
> as per the instructions (which are a little unclear incidentally about the
> syntax of entering document names in the property window).
> 
> I fixed this, but Zope still returns the error message now and then *when I

not being funny or anything, but are you sure you entered the source correctly? Post the source *as you entered it* and let us all peruse it...

As a dopey example, checkout http://medfac10.ncl.ac.uk/insult for a Shakespearean Insult Generator using a variant on random code (DTML src included). (my favourite so far: "thou art a yeasty, dismal-dreaming, maggot-pie!") :) 

Change a line like <!--#var expr="_.whrandom.choice(line1)"--> to add another level of indirection (<!--#var expr="_['_.whrandom.choice(dtmldocs)']"--> where dtmldocs is a lines property of dtml document ids and you should be away (warning! - not tested!).

> 
> PS -- Our Zope site is www.english.lsu.edu -- you're welcome to look around
> starting Aug. 19th.  Zope is IDEAL for building departmental websites at
> universities.  You have no idea how enthusiastic people down here are about
> it!
> 

You're dead right there. I'll be deploying our system at three sites within two months...so little time, so much to do (esp. when I havenn't got our resource db and multiple choice engine sorted out yet!). :)

tone out.