[Zope-dev] adding a ZSQLmethod programmaticaly throug the WEB

Joachim Schmitz js@aixtraware.de
Wed, 8 Aug 2001 15:37:06 +0200 (CEST)


No reason to be sorry :-))

thank you very much, that did it.


On Wed, 8 Aug 2001, Steve Spicklemire wrote:

> Sorry.. I should be more clear!
>
> The "object" you want is the Product ZSQLMethods. Try this (url is an
> URL to a *Folder*)
>
>      object=3DZPublisher.Client.Object(url +
> '/manage_addProduct/ZSQLMethods', username=3Duser, password=3Dpassword)
>
> and then:
>
>      call(object.manage_addZSQLMethod, id=3Dname, title=3D'',
> connection_id=3D'testDB', arguments=3D'', template=3Dopen(f,'rb').read(=
))
>
> -steve
>
> On Wednesday, August 8, 2001, at 01:46 AM, Joachim Schmitz wrote:
>
> > Hi,
> >
> > I resend this quesstion with a little better re-line, and hopefully s=
ome
> > better explanation.
> >
> > I try to add a ZSQLmethod by means of a modified load_site.py from th=
e
> > utilities directory of the Zopedistribution.
> >
> > it has a upload_html procedure with the line:
> >
> >    call(object.manage_addDTMLMethod, id=3Droot, file=3Df)
> >
> > which uses the ZClient.py to call the URL:
> >
> > http://www.myhost.de/manage_addDTMLMethod
> >
> > and submit the parameters in the post. this one works.
> >
> > I created an upload_sql: with the corresponding call:
> >
> >     call(object.manage_addZSQLMethod
> >                            ,submit=3D"Add"
> > 	                   ,id =3D root
> > 	                   ,template=3Dtemplate
> > 			   ,title=3D""
> > 			   ,connection_id=3Dstring.strip(dbcon)
> > 			   ,arguments=3Dparams)
> >
> > but thisone always fails with a "Not found error" for
> >
> > http://www.myhost.de/manage_addZSQLMethod
> >
> > So what is the correct path to the manage_addZSQLMethod ?
> >
> > I am quite sure, that the name is correct
> >
> >
> > Mit freundlichen Gr=FC=DFen
> >
> > Joachim Schmitz
> >
> > AixtraWare, Ing. B=FCro f=FCr Internetanwendungen
> > H=FCsgenstr. 33a, D-52457 Aldenhoven
> > Telefon: +49-2464-8851, FAX: +49-2464-905163
> >
> >
> >
> > _______________________________________________
> > Zope-Dev maillist  -  Zope-Dev@zope.org
> > http://lists.zope.org/mailman/listinfo/zope-dev
> > **  No cross posts or HTML encoding!  **
> > (Related lists -
> >  http://lists.zope.org/mailman/listinfo/zope-announce
> >  http://lists.zope.org/mailman/listinfo/zope )
>

Mit freundlichen Gr=FC=DFen

Joachim Schmitz

AixtraWare, Ing. B=FCro f=FCr Internetanwendungen
H=FCsgenstr. 33a, D-52457 Aldenhoven
Telefon: +49-2464-8851, FAX: +49-2464-905163