[Zope] User DB, GUF, et al broken under 2.1.7?
Is it just me or are about all the third party ACL folders broken in 2.1.7? I have tired User DB, and GUF and can't seem to get either to work. I was one of the bright fellows who updated to 2.1.7 immediately when it became available from 2.1.4, and now all my user folders are broken and I (like an idiot) did not make a backup before upgrading. (Well I did, but I actually have done some work on the site since then, and it seems the Data.fs is not compatable if I take it from 2.1.7 and try to use it in 2.1.4. ARGH... Help! -- Did I say I was a sardine? Or a bus??? ___ Zope maillist - [EMAIL PROTECTED] 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 )
Re: [Zope] User DB, GUF, et al broken under 2.1.7?
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 In article [EMAIL PROTECTED], [EMAIL PROTECTED] writes Is it just me or are about all the third party ACL folders broken in 2.1.7? I have tired User DB, and GUF and can't seem to get either to work. I was one of the bright fellows who updated to 2.1.7 immediately when it became available from 2.1.4, and now all my user folders are broken and I (like an idiot) did not make a backup before upgrading. (Well I did, but I actually have done some work on the site since then, and it seems the Data.fs is not compatable if I take it from 2.1.7 and try to use it in 2.1.4. ARGH... Help! Have you actually tried reinstalling 2.1.4? I've never had a problem with installing an older version on top of a newer one. - -- Regards, Graham Chiu gchiuatcompkarori.co.nz http://www.compkarori.co.nz/index.php Powered by Interbase and Zope -BEGIN PGP SIGNATURE- Version: PGPsdk version 1.7.1 iQA/AwUBOUvpdLTRdIWzaLpMEQIvNQCgi4zLDaPUhmj5i6AbAmT/lXVrT+cAoJnz mmtHvXt8j6sXQ3nhRIGiuErV =V8V7 -END PGP SIGNATURE- ___ Zope maillist - [EMAIL PROTECTED] 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 )
[Zope] Re: passing variables
josh on wrote: Is there a way to pass variables from one page to another using an a href but not including them in the url after a ?? sorry, I know this is an html question, but I figured it was pretty zope related. Josh, This is a "[EMAIL PROTECTED]" question, not a "[EMAIL PROTECTED]" question, so I've moved the thread to there. You can do what you want in a couple of ways: 1: Cookies Can your HTTP clients use Cookies? You can send a cookie on one page and retrieve it on the next. Look at the "Zope Developer's Guide" and for information on Cookies and the RESPONSE variable. Watch out though -- if you pass data in a cookie, and expect to use that data retrieved later, you could be opening yourself up to a security risk. A client could change the data in the cookie to mean something different, and you might never find out. 2: Sessions Use one of the NNNSession products, such as FSSession or SQLSession. These use cookies behind the scenes, but present you with a nice programming interface. Also, your actual data (session variable and so forth) live on the server. The cookie just tells the server where to find them. Thus, no part of your data is entrusted to the client. I'd suggest you look at the FSSession product: http://www.zope.org/Members/gaaros/FSSession Or perhaps HappySession: http://www.zope.org/Members/hungjunglu/Products/HappySession -- Steve Alexander Software Engineer Cat-Box limited http://www.cat-box.net ___ Zope maillist - [EMAIL PROTECTED] 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 )
Re: [Zope] SMTP server external method??
Hi, If not, how do you handle email in zope for a web-based system?? just periodically create objects from the contents of /var/spool/mail/user ... or use some other method?? ideally, the object's various properties would be set upon instantiation...stuff like header fields would correspond to properties...etc... For those that handle email in Zope, how do you approach this?? I didn't try it, but I would prefer the following method: First create a Zope-Application that creates objects from an URL like http://your_host/your_appplication?sender=foo@barsubject=the_ultimate_subject;. Then create a mail-filter to pipe the mail to a script. This script gets the headers and other infos from the incoming mail and forms an url for your Zope-application. Pipe this URL to a command-line Browser like lynx. lynx -dump http://your_host/your_appplication?sender=foo@barsubject=the_ultimate_subject;. I hope this should do, what you want ... Robert ___ Zope maillist - [EMAIL PROTECTED] 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 )
[Zope] ISP supporting zope
hi everyone, can anybody give me names of ISP's providing zope support. I wil prefer US for the ISP locations. Is any such list available on the net or zope site. Thanks ___ Zope maillist - [EMAIL PROTECTED] 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 )
Re: [Zope] ISP supporting zope
+[ Rajil Saraswat ]- | hi everyone, | can anybody give me names of ISP's providing zope support. I wil prefer | US for the ISP locations. Is any such list available on the net or zope | site. Yes. -- Totally Holistic Enterprises Internet| P:+61 7 3870 0066 | Andrew Milton The Internet (Aust) Pty Ltd | F:+61 7 3870 4477 | ACN: 082 081 472 | M:+61 416 022 411 | Carpe Daemon PO Box 837 Indooroopilly QLD 4068|[EMAIL PROTECTED]| ___ Zope maillist - [EMAIL PROTECTED] 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 )
Re: [Zope] ISP supporting zope
+[ Rajil Saraswat ]- | hi everyone, | can anybody give me names of ISP's providing zope support. I wil prefer | US for the ISP locations. Is any such list available on the net or zope | site. | Thanks Hrm obviously my Zen attempt to get you to help yourself failed miserably, since you simply posted again without checking the obvious places. http://www.zope.org/Resources/ I'm not giving any more clues. If you want more help, you'll have to buy a vowel, and since I've only got five left, they're very expensive d8) -- Totally Holistic Enterprises Internet| P:+61 7 3870 0066 | Andrew Milton The Internet (Aust) Pty Ltd | F:+61 7 3870 4477 | ACN: 082 081 472 | M:+61 416 022 411 | Carpe Daemon PO Box 837 Indooroopilly QLD 4068|[EMAIL PROTECTED]| ___ Zope maillist - [EMAIL PROTECTED] 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 )
Re: [Zope] ZODB or not ZODB?
charset="iso-8859-1" I am implementing a document Library using Zope. It has an exhaustive index with several thousand topics in an outline residing on a PostgreSQL database. This works well and I like it. My question is where is the best place to store the documents themselves? They will be static HTML documents ranging from 1-50Kb in size roughly. There will probably be at least 10,000-15,000 of these documents in the library once all is said and done. In my mind I have three options: 1. Store them on the filesystem. 2. Store them in a PgSQL table as blobs. 3. Store them as DTML Docs in the ZODB. The filesystem, imho. This lets you spread things out over multiple disks and even (perhaps) multiple systems. Worst case you've got 50k x 15k = 750M. Big for a ZODB (?), but no sweat for a file system. PgSQL blobs are not yet ready for prime time. For one thing, I think they are all created in the same directory. And I'm a big PgSQL fan, so this pains me to say, but it is true. They are working on it. See the TOAST project in the postgresql mailing lists. You want to spread the documents out over a couple of directories. I've set up systems where everything had an ID and we'd split things up via digits in the id. I.e. document 252a8b7c is file 25/2a/7b/25218b7c. You could even compress the files if you wanted to. And you could use the "LocalFileSystem" (is that it?) product to serve up the files through Zope. You could tweak it to decompress too. I would like to eventually have full text searching capabilities, so that makes #1 less attractive (I would likely need my own Python method to do it). #2 is somewhat of a pain to implement due to limitations in the PgSQL row size and text searching would be slow. With #3 I could in theory use a ZCatalog to implement the searching, so that is done for me. I'd put the full text search into PostgreSQL. When the doc comes in, strip out the keywords and index it. Is ZODB up to the task of storing this quantity of objects? What problems might I run into? Is it a wise idea, could a data.fs file of this size (~3-400MB) become too easily corrupted? Should I use a separate data.fs file just to store the documents (ie using mountedFileStorage)? Or is it better to use method #1 or #2? Information from anyone with experience in this regard is greatly appreciated. We implemented a system using #1. Actually, we had lots of little documents so we concatted and gziped them in batches of 200, keeping the filename, offset, and length. Turns out it was quick enought to unzip the file and pick out the document of interest. And batching them up kept the compression ratio up. System worked great, but was cancelled about a week before it was going to go online. ouch. I'll let others speak to 3. I've never had a problem with ZODB, but I've never put 750MB in it. -- cary -Casey Duncan [EMAIL PROTECTED] --__--__-- ___ Zope maillist - [EMAIL PROTECTED] 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 )
[Zope] nested dtml-in with sql method -namespace problem (?)
hi all, i have posted this question a while back, but got no replies. maybe imy question is a bit off or unclear. so here it is again. rephrased. i have 2 sql methods. sql1, and sql2. sql 2 got the parameter for it's query from sql1. as follows: -- dtml-in "sql1" dtml-in "sql2(obj=myobj)" do stuff /dtml-in /dtml-in -- sql1 is just a query that returns myobj that will be used by sql2. this used to work on 2.1.6 but not anymore on 2.2 i guess tmyobj is not in the namespace. even tried passing _.None, _,obj=myobj but resulted the same error. the traceback raceback (innermost last): File /home/kdie/Zope-2.2.0b1-src/lib/python/ZPublisher/Publish.py, line 222, in publish_module File /home/kdie/Zope-2.2.0b1-src/lib/python/ZPublisher/Publish.py, line 187, in publish File /home/kdie/Zope-2.2.0b1-src/lib/python/Zope/__init__.py, line 221, in zpublisher_exception_hook (Object: ElementWithAttributes) File /home/kdie/Zope-2.2.0b1-src/lib/python/ZPublisher/Publish.py, line 171, in publish File /home/kdie/Zope-2.2.0b1-src/lib/python/ZPublisher/mapply.py, line 160, in mapply (Object: index_html) File /home/kdie/Zope-2.2.0b1-src/lib/python/ZPublisher/Publish.py, line 112, in call_object (Object: index_html) File /home/kdie/Zope-2.2.0b1-src/lib/python/OFS/DTMLMethod.py, line 168, in __call__ (Object: index_html) File /home/kdie/Zope-2.2.0b1-src/lib/python/DocumentTemplate/DT_String.py, line 500, in __call__ (Object: index_html) File /home/kdie/Zope-2.2.0b1-src/lib/python/DocumentTemplate/DT_In.py, line 611, in renderwb (Object: qry_msgs_by_par_id(par_id=0)) File /home/kdie/Zope-2.2.0b1-src/lib/python/OFS/DTMLMethod.py, line 164, in __call__ (Object: show_subtree_index) File /home/kdie/Zope-2.2.0b1-src/lib/python/DocumentTemplate/DT_String.py, line 500, in __call__ (Object: show_subtree_index) File /home/kdie/Zope-2.2.0b1-src/lib/python/DocumentTemplate/DT_In.py, line 633, in renderwob (Object: qry_msg_thread(par_id=obj_id)) File /home/kdie/Zope-2.2.0b1-src/lib/python/DocumentTemplate/DT_Util.py, line 339, in eval (Object: qry_msg_thread(par_id=obj_id)) (Info: qry_msg_thread) File string, line 0, in ? File /home/kdie/Zope-2.2.0b1-src/lib/python/Shared/DC/ZRDB/DA.py, line 444, in __call__ (Object: qry_msg_thread) File /home/kdie/Zope-2.2.0b1-src/lib/python/DocumentTemplate/DT_String.py, line 500, in __call__ (Object: string) File /home/kdie/Zope-2.2.0b1-src/lib/python/Shared/DC/ZRDB/sqlvar.py, line 168, in render (Object: obj_id) Missing Input: (see above) any clues, hints are appreciated thanks -- -- http://www.kedai.com.my/kk Am I Evil? ___ Zope maillist - [EMAIL PROTECTED] 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 )
Re: [Zope] newbie changingover to zope from html/cgi??
can i replace javascript with python/DTML. I have used drop down menus in the pages using javascript. Is these available in Zope or is there some way of using these. I'd keep the drop-down menus in javascript. You can do similar things in zope (i.e. the tree tag or the tab bar at the top of the management interface), but then every change is a fetch back to the web server. If you keep the javascript then it all happens at the client. If you want you can generate the javascript with dhtml. That way the contents of the menus can follow your site. You'd have to set the comtent type so that the browser thinks it is javascript. (hmm, how is javascript cached??) -- cary [snip] ___ Zope maillist - [EMAIL PROTECTED] 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 )
[Zope] Re: Zope digest, Vol 1 #834 - 57 msgs
Deryk Barker [EMAIL PROTECTED] To: zope [EMAIL PROTECTED] Subject: [Zope] Worldpilot and imap problem Looking through the archives I couldn't find anything which semed quite relevant, so: I'm currently running Linux mandrake 7.02 and have enabled the IMAP (4.7-7) server. I can read/write mail via netscape using imap, so I presume the setup is OK. (Although i can't quite get pine to talk to it, maybe something isn't quite right). Unfortunately, whenever I log onto worldpilot (and yes I have edited the DOMAIN.py file) the hourglass appears, presumably while attempting to fetch my mail and top shows me a python process running as zope, chewing up anything up to 80-90% of the CPU. All that seems to work is restarting zope. I would guess that you are using the Washington University IMAP daemon, which has unfortunately chosen to treat your entire home directory as a possible mailbox -- what is probably happening is that you are not really hung, but are stuck running stat() on every file under your home directory. To test this, add a new, bogus user to your system, and clean out any "skeleton" cruft from ~/bogus. Try logging in to WorldPilot -- if that works, then you need to search the archives from February for notes on WU IMAP. Trimming the contents of my mailbox down to just 6 messages didn't seem to make any difference. Anyone shed any light? Oh yes, I have applied the imap.py.diff patch to the python library. -- === Tres Seaver[EMAIL PROTECTED] Digital Creations"Zope Dealers"http://www.zope.org ___ Zope maillist - [EMAIL PROTECTED] 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 )
Re: [Zope] ZODB or not ZODB?
- Original Message - From: "Casey Duncan" [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Friday, June 16, 2000 6:35 PM Subject: [Zope] ZODB or not ZODB? My question is where is the best place to store the documents themselves? They will be static HTML documents ranging from 1-50Kb in size roughly. There will probably be at least 10,000-15,000 of these documents in the library once all is said and done. In my mind I have three options: 1. Store them on the filesystem. 2. Store them in a PgSQL table as blobs. 3. Store them as DTML Docs in the ZODB. Is ZODB up to the task of storing this quantity of objects? What problems might I run into? Is it a wise idea, could a data.fs file of this size (~3-400MB) become too easily corrupted? Should I use a separate data.fs file just to store the documents (ie using mountedFileStorage)? Or is it better to use method #1 or #2? Information from anyone with experience in this regard is greatly appreciated. There are people who have experience with giant ZODBs... some people have run into the 2GB ext2fs file size limit. My Data.fs has been around ~100MB. FileSystem Storage is really quite stable, and is not likely to get corrupted no matter what the size. If you need to store the docs in multiple drives, you can use the mountable storages to set up another file on the other disk. One thing to be aware of: 10-15K documents is too much for a single Folder. You either want to break the docs up into multiple folders, or hang on for the BTreeFolder product. One other nice thing about storing in the ZODB: it's pretty easy to make your documents automatically add themselves to the ZCatalog. No need to manually update the indexes. (This would be true of PgSQL, but not the fs.) Kevin ___ Zope maillist - [EMAIL PROTECTED] 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 )
Re: [Zope] User DB, GUF, et al broken under 2.1.7?
Yes I have, and it breaks all my ZSQL methods if I do that. On Sun, Jun 18, 2000 at 09:11:15PM +1300, Graham Chiu wrote: Hash: SHA1 In article [EMAIL PROTECTED], [EMAIL PROTECTED] writes Is it just me or are about all the third party ACL folders broken in 2.1.7? I have tired User DB, and GUF and can't seem to get either to work. I was one of the bright fellows who updated to 2.1.7 immediately when it became available from 2.1.4, and now all my user folders are broken and I (like an idiot) did not make a backup before upgrading. (Well I did, but I actually have done some work on the site since then, and it seems the Data.fs is not compatable if I take it from 2.1.7 and try to use it in 2.1.4. ARGH... Help! Have you actually tried reinstalling 2.1.4? I've never had a problem with installing an older version on top of a newer one. - -- Regards, Graham Chiu gchiuatcompkarori.co.nz http://www.compkarori.co.nz/index.php Powered by Interbase and Zope Version: PGPsdk version 1.7.1 iQA/AwUBOUvpdLTRdIWzaLpMEQIvNQCgi4zLDaPUhmj5i6AbAmT/lXVrT+cAoJnz mmtHvXt8j6sXQ3nhRIGiuErV =V8V7 ___ Zope maillist - [EMAIL PROTECTED] 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 ) -- "But I don't like Spam" ___ Zope maillist - [EMAIL PROTECTED] 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 )
[Zope] data integrity
Yellow, Is there any way to check data.fs integrity? If data.fs becomes corrupted how can i fix it or even know about it? thanks --- Hugo Ramos - [EMAIL PROTECTED] ZopersORG - http://www.zopers.org ___ Zope maillist - [EMAIL PROTECTED] 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 )
Re: [Zope] Problem with adding items to ZClass instance
I discovered something bizarre that happens in my 2.1.4 and 2.2b1 installations. Bizarre, yes, unusual, no. I have a ZClass based on ObjectManager. In an instance of the ZClass, I can "Add" most of the available objects (DTML Documents, DTML Methods, User Folder, MailHost to name a few). However, for at least two items (TinyTable and ZMySQL DB Connection), when I add them, they show up in the container folder, not in the ZClass instance. Then, if I check it to delete it, it gives a "does not exist" error. Upon refreshing the container folder, the item still shows, but then I *can* delete it. Equally interesting is that I can Copy the item from the container folder and successfully Paste it into the ZClass instance. However, since ZMySQL DB Connections don't support Copy/Paste, that won't work. What's going on? Is it a problem with my ZClass, the Product manage_add, or Zope? Or me? This is not so easy to answer. ZClasses do strange things to adding items. If your ZCLass definition (in the Product) is nested in another ZClass, then it is your ZClass. If the ZClass definition is defined in the top level of your product. There may be other things going on, including all of the above ;-) You'll need to provide more details to be able to say more about this. hth Rik ___ Zope maillist - [EMAIL PROTECTED] 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 )
Re: [Zope] data integrity
On Sun, Jun 18, 2000 at 08:18:50PM +0100, Hugo Ramos wrote: Yellow, Is there any way to check data.fs integrity? If data.fs becomes corrupted how can i fix it or even know about it? Red, I say. ;) You'll know it when there is a corruption, Zope will let you know when 1. starting up 2. encountering a record that is corrupted You can use Ty Sarna's Tranalyzer: http://www.zope.org/Members/tsarna/Tranalyzer to analyze you Data.fs transactions. And the "Recovering Corrupted Data.fs ZODB files" How-To tells you how to use it: http://www.zope.org/Members/itamar/CorruptedZODB -- Martijn Pieters | Software Engineermailto:[EMAIL PROTECTED] | Digital Creations http://www.digicool.com/ | Creators of Zope http://www.zope.org/ | The Open Source Web Application Server - ___ Zope maillist - [EMAIL PROTECTED] 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 )
[Zope] sql-statements in DTML-Methods....
Hi. This is one of the first times I'm working with Zope and databases. Until now - if I wanted to work with a databse, i always created a Z SQL method that I called from my DTML-method via dtml-call "add_item(param1 = ..., param2 = ..., param3 = ..., ..."(for example) or dtml-in get_items ... /dtml-in (for example) In the Z SQL method 'add_item' or 'get_items', my SQL statement are defined. My question is now: Do I have to define one Z SQL Method for every SQL statement I want to perform on my database or is it possible to define SQL-statements and database requests in my DTML-method? Am I missing something? Any idea? Thanks a lot. Regards, Marc mailto:[EMAIL PROTECTED] ___ Zope maillist - [EMAIL PROTECTED] 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 )
Re: [Zope] ZClass-within-a-ZClass not in subobjects list?
On Sun, Jun 18, 2000 at 01:28:26PM -0400, Tres Seaver wrote: Matt Behrens [EMAIL PROTECTED] wrote: No matter what I do, I can't seem to make a ZClass a subobject of another ZClass. I'm really not sure what I'm missing. Here's what I've done: [snip] There are a couple of items in play here: * Nested ZClasses are *always* addable in their containing ZClass, so they don't show up as options in the Subobjects tab. OK, cool. That makes sense. * If you have *exactly one* nested ZClass in a container ZClass, *and* you have not specified any "outside" objects as addable on the Subobjects tab, then the only objects which will be addable in the container ZClass are instances of the nested one; in this case, the management interface does not display a dropdown list, but only the "Add" button (try clicking Add on your Whiteboard object's Contents tab). What was throwing me here is that when I'd hit the ``Add'' button, I'd get ``Resource not found''. After mumbling on #zope for awhile, I finally went digging though the mailing list archives and discovered an issue dating at least back to September 1999 indicating that you had to go into the inner ZClass's factory and hit ``Change'' to make it work. I did this and it worked. Collector #1334 has details. [snip] Patches gratefully accepted :) When I discovered that what I was seeing was a bug, that was the first thing I tried to do -- find the problem and fix it -- but at this point, I'm too green yet to figure it out. Maybe in the future. Thanks! -- Matt Behrens [EMAIL PROTECTED] Student of Zope Zen Owner/Administrator, zigg.com ___ Zope maillist - [EMAIL PROTECTED] 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 )
[Zope] Re: Catalog Aware ZClass
Hi Scott, Yes, this howto is slightly dusty. If you're running a recent build (say 2.1.4 and higher), I guess you can disregard the bit about patching. The rest of this doc should still be applicable. Let us know if you are stuck somewhere. Cheers. Alexandre At 10:06 16/06/2000 -0700, you wrote: Date: Thu, 15 Jun 2000 15:32:25 -0700 Subject: [Zope] Catalog Aware ZClass From: Scott Burton [EMAIL PROTECTED] Hello fellow Zopists, I want to create a catalog aware Zclass. I would like to include some specific indexable metadata when creating an instance of that object. So when I add an instance of that object it asks me for some information that gets indexed by ZCatalog to be searched later on. I have tried following the instructions given here: http://www.zope.org/Members/AlexR/CatalogAware But I noticed there is some information which may be outdated. It also suggests having to Patch CatalogAwareness.py I am not sure if this is still required? Or, where do I start? TIA! ___ Zope maillist - [EMAIL PROTECTED] 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 )
Re: [Zope] Multiple virtual hosts and domains
Not sure what your problem is, since you didn't mention anything you did. If you have a IRC client got to irc.openprojects.net #zope and I might be able to help you there. I have it running (no production yet) behind apache's proxypass -Th On 18 Jun, Hugo Ramos wrote: Yellow, After testing SiteAccess for about 100 times... i still can't get zope to serve multiple virtual hosts and domains... I would like very much that someone with a successful siteaccess instalation in a real production site could get in touch with me and try to get this working. please don't tell me to read the siteaccess how-to because that didn't work. thanks ppl --- Hugo Ramos - [EMAIL PROTECTED] ZopersORG - http://www.zopers.org ___ Zope maillist - [EMAIL PROTECTED] 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 )
Re: [Zope] Problem with adding items to ZClass instance
On Sun, 18 Jun 2000, Rik Hoekstra wrote: This is not so easy to answer. ZClasses do strange things to adding items. If your ZCLass definition (in the Product) is nested in another ZClass, then it is your ZClass. If the ZClass definition is defined in the top level of your product. There may be other things going on, including all of the above ;-) You'll need to provide more details to be able to say more about this. I'm not sure what kind of information would help. Let me know what and I'll be happy to provide it. I'll provide the Product .zexp which includes a single top-level ZClass, a couple dozen methods and a single property sheet, if that would help. There's nothing especially complex about it. It uses ZSQLMethods (w/ MySQLDA) and TinyTables, and once I can get the stuff in the right place in the instance, everything works just fine. Thanks! --- Ron ___ Zope maillist - [EMAIL PROTECTED] 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 )
[Zope] Re: [Zope-dev] sql-statements in DTML-Methods....
Zope differs from PHP and ASP systems in this regard. I don't think anyone using Zope that I've seen inlines SQL inside DTML.The separation of SQL and presentation via DTML is intentional. Though it's not always as expedient, the intent of the separation is to provide you with layers of abstraction that make it easier to maintain and modify your code later. That said, I imagine you could do it by constructing a string inside DTML that has the sql query and passing it in to a dummy SQL method that performs the query and returns the results. Marc LUDWIG wrote: My question is now: Do I have to define one Z SQL Method for every SQL statement I want to perform on my database or is it possible to define SQL-statements and database requests in my DTML-method? Am I missing something? Any idea? Thanks a lot. ___ Zope maillist - [EMAIL PROTECTED] 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 )
Re: [Zope] Multiple virtual hosts and domains
Hugo Ramos wrote: After testing SiteAccess for about 100 times... i still can't get zope to serve multiple virtual hosts and domains... I would like very much that someone with a successful siteaccess instalation in a real production site could get in touch with me and try to get this working. I just recently asked this question and got it to work. This setup works if you have several subdomains 'sitea.domain.tld' and 'siteb.domain.tld' etc. It may have to be modified to work with other setups - don't ask me how! - create folders sitea, siteb, and so on in your root zodb directory - put a siteroot in each folder, leaving all fields except name blank - make a dtml method in the root directory called virtual_hosts or something, consisting of the following script: dtml-comment Get subdomain: /dtml-comment dtml-let hostname="_.string.join(_.string.split(_.string.split(HTTP_HOST,':')[0], '.')[0], '')" dtml-comment Is there a folder named as this subdomain? /dtml-comment dtml-try dtml-if "[hostname]" dtml-comment Set logical root: /dtml-comment dtml-call "REQUEST.set('SiteRootPATH', '/')" dtml-comment Add physical root: /dtml-comment dtml-call "REQUEST.path.append(hostname)" /dtml-if dtml-except KeyError dtml-call "RESPONSE.redirect('http://www.domain.tld/site_not_found')" /dtml-try /dtml-let - Create a Site Access Rule in the root folder and have it call this method. This should work, but don't ask me how (credit goes to Ethan Mindlace Freeman, who gave me these instructions). Good luck! -- Building highways to reduce traffic is like loosening your belt to reduce obesity. ___ Zope maillist - [EMAIL PROTECTED] 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 )
RE: [Zope] Products vs. ZClasses- Design Question
On Fri, 16 Jun 2000, Charlie Derr wrote: Jeff wrote: ~ As explained above, this advantage is shared by Python Products also. You ~ do *not* want to write application logic with DTML. At a minimum, use ~ Python Methods. Otherwise, use Python. ~ Let me apologize in advance because i think this is going to turn out to be a really stupid question. I'm never gonna know the answer if i don't ask it though. :-\ I've seen this mentioned a lot (advice not to write application logic in DTML). If one wants to use pure python (and not Products and not external methods) to create complex actions/relationships, then where does one place this code? Obviously i can litter my DTML with python expressions, but this seems to be what is being recommended against strongly. Is there a way to use python "correctly" without writing a product and without encapsulating it in an external method? You have two choices: 1) Use PythonMethods, found at: http://www.zope.org/Members/4am/PythonMethod These work like DTML Methods, only you write them in Python. They are relatively safe, also. 2) Create a base class in Python, register it with Zope as a ZClass Base, and specify it as a parent class to your ZClass. i.e.: FILE: TestBase.py - class TestBase: """My ZClass Base class.""" def __init__(self): self.foo = 'Foo' def getFoo(self): return self.foo def setFoo(self, value): self.foo = value def initialize(context): context.registerBaseClass(TestBase) FILE: __init__.py - import TestBase def initialize(context): TestBase.initialize(context) Put these two files in your lib/python/Products/TestBase directory. Then, restart your Zope. Now, add a new product called Test. Inside it, create a ZClass called 'Test' with a meta-type of 'Test'. Specify TestBase as the base class. Inside the Test ZClass, create a DTML Method called index_html. Give it the following contents: dtml-var standard_html_header P Initial foo: dtml-var getFoo /P P dtml-call expr="setFoo('Hello, world.') New foo: dtml-var getFoo /P dtml-var standard_html_footer Create an instance of the Test ZClass, and view its index_html. Voila. Hope this helps, tesmia, ~c --Jeff --- Jeff K. Hoffman 704.849.0731 x108 Chief Technology Officer mailto:[EMAIL PROTECTED] Going Virtual, L.L.C. http://www.goingv.com/ ___ Zope maillist - [EMAIL PROTECTED] 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 )
Re: [Zope] get fssession value
On Sat, 17 Jun 2000, Richard Bartels wrote: Hello, I'm sure this is simple, but have not been able to come up with the correct way. Yep, there's always a simple way.. (o8 If I do this, dtml-call "FSSession['username'].update(REQUEST.form)" and then retrieve with, FSSession['username'] I get {'username':'something'} when of course all I want is something. What you really should use is something more like: dtml-call "FSSession.set('username', REQUEST.form['username'])" or, as is acceptible MOST of the time (when there is not another object of the same name hanging about ) : dtml-call "FSSession.set('username', username)" Thanks much, Rick No problems. Have a better one, Curtis dtml-var standard_work_disclaimer ___ Zope maillist - [EMAIL PROTECTED] 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 )