[Zope] asp request and response objects

David Kovach dave@kovach.com
Wed, 25 Apr 2001 10:50:47 -0500


Thanks David. That does help.

I think my confusion is in thinking about concepts from the
ASP world and seeing how they are emulated at least in concept.
Many of the flaws of ASP - most of which exist in the design
pattern (or lack thereof) of how applications are built dont
carry over into the ZOpe world due to its OO nature. Do you
agree with this?

I see the obvious difference of elements (what as you said
would of been included in the asp world) being called as
objects and pages being built from a few tags with supporting
code contained in each tag object.

>From that point - what is best practice? In terms of business
logic and application logic - how do you (coming from ASP also)
structure your pages and applications with Zope?

Are you in fact using DTML to build pages and within each
object your referencing other objects, html, and python
scripts or what?

I would be interested to see (or help design/draw up) some
architecture diagrams showing process and program flows...
this would be helpful to newbies like myself - which there
are sure to more of. Now is the time to rally the troops -
before .NET hits the public airwaves.

thanks again,

David Kovach
dave@kovach.com
SAP


>From: "David Burton" <eloquence@eloquent-designs.f2s.com>
>To: <dave@kovach.com>
>Subject: Re: [Zope] asp request and response objects
>Date: Wed, 25 Apr 2001 11:12:01 +0100
>
>You seem to have a slightly confused idea of how to use ZOPE, but that's
>perfectly normal - it kinda does that to everyone initially.
>As an ASP developer that's trying to use ZOPE as much as possible, there 
>are
>various things that would be done using databases
>and a reasonable amount of code that you can do in a few lines of DTML.
>For example, dynamic news lists, or dynamic thumbnail libraries can be done
>more easily, and also things that there are products for.
>
>As for the response object - you have some of the functions replicated in
>other features, but you don't have the response object as such. Instead of
>response.write you'd use print in python scripts (but remember to use
>'return printed' at the end of the script).
>
>WRT the request object, the variables can be accessed from the REQUEST
>object. For form processing, you would often just refer to the field names
>(e.g. to print the username field from the processing script in DTML, use
><dtml-var username>).
>
>The first difference that I've seen is that is more forces you to structure
>your pages to be more object oriented - relating it to ASP, you're more
>thinking of breaking things down to sub-pages, that in ASP you'd do by
>creating an ASP with various include statements in.
>The second is that you gradually become aware that you're working in an
>object hierarchy all the time, which means that you can create a folder 
>full
>of documents, and more readily print details about each dynamically.
>
>Unless you need to share the data with other applications, sticking with 
>the
>ZODB in preference to a relational database is often a good idea, although
>as an ASP user initially it can be easier to get one of the ODBC database
>adaptors, and creating a few SQL queries, etc and DTML to process them,
>which will give you a better feel for the object-orientation of ZOPE while
>keeping the returning/changing data parts themselves well within the common
>ground with ASP (ie SQL statements).
>
>Hope this helps,
>David Burton
>----- Original Message -----
>From: "David Kovach" <davidkovach@hotmail.com>
>To: <zope@zope.org>
>Sent: Tuesday, April 24, 2001 7:38 AM
>Subject: [Zope] asp request and response objects
>
>
> > Hi -
> >
> > Just getting on board with Zope and Python...
> > converting over from MS ASP web application
> > development AND dont want to invest/waste time
> > with JSP or servlets for that matter.
> >
> > I look forward to seeing how to further work
> > with ZOPE with XML/XSLT - page templates cool!
> >
> > (end of my blah intro!)
> >
> > Can anyone share with me in simple terms - how
> > ZOPE replicates or depracates the ASP object
> > of REQUEST and RESPONSE to build dynamic pages??
> >
> > And I have read and seem to assume that keeping
> > logic to add dynamic content should be kept to
> > Python code thats called from a DTML method or
> > something??? Set me straight...
> >
> > Thanks - and I look forward to interacting
> > with you all more...
> >
> > Sincerely,
> >
> > David Kovach
> > dave@kovach.com
> > dave.kovach@sap.com
> >
> >
> > _________________________________________________________________
> > Get your FREE download of MSN Explorer at http://explorer.msn.com
> >
> >
> > _______________________________________________
> > Zope maillist  -  Zope@zope.org
> > http://lists.zope.org/mailman/listinfo/zope
> > **   No cross posts or HTML encoding!  **
> > (Related lists -
> >  http://lists.zope.org/mailman/listinfo/zope-announce
> >  http://lists.zope.org/mailman/listinfo/zope-dev )
>

_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com