[Zope-dev] Redirecting from the manage interfaces.
Hi. I've been browsing through the Zope and Zope-dev archives without finding anything related to this, please stop me if it has already been dealt with. :) technical person = someone who doesn't mind fuzzing around with the manage_main pages non-technical person = someone who needs everything in bright nice colors and would start crying if they saw the manage_main page, or anything similar. I have a Product that allows a customer of mine to add some nice pictures (Image object) to a folder. The add-method is nice and doesn't display any horrible technical information. I wasn't very keen on making a add-method for both the technical person and the non-technical person, so I hacked the source code a bit. I changed the the lib/python/OFS/Image.py It used to look like this: """ def manage_addImage(self, id, file, title='', precondition='', content_type='', REQUEST=None): [...] if REQUEST is not None: try:url=self.DestinationURL() except: url=REQUEST['URL1'] REQUEST.RESPONSE.redirect('%s/manage_main' % url) return id """ Which I changed into: """ def manage_addImage(self, id, file, title='', precondition='', content_type='', REQUEST=None, redir=None): [...] if redir is not None: REQUEST.RESPONSE.redirect('%s' % redir) elif REQUEST is not None: try:url=self.DestinationURL() except: url=REQUEST['URL1'] REQUEST.RESPONSE.redirect('%s/manage_main' % url) """ Now I can redirect the victim... erm.. customer to the method I want to, and they are pleased that they don't have to see the management interface. This saves me a lot of time, since I don't have to make several add-methods, and maintainace is a more joyable happening. :) This 'redir' thing is something I've stuck into a lot of .py files (for example, I use it in the manage_delObjects and others). And it is something I do every time a new Zope release comes out. Could this be to any use for anybody besides me? And if it could, how about adding it to the next release? ___ Zope-Dev maillist - [EMAIL PROTECTED] 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 )
Re: [Zope-dev] Redirecting from the manage interfaces.
On Sat, 15 Jul 2000, Shane Hathaway wrote: call, it won't redirect. So you should be able to achieve the same results just by invoking manage_addImage without including the REQUEST object. But I have to pass something with the REQUEST, or else it won't add the image, right? A convention I've seen that works just a little better is to redirect based on the existence of a RESPONSE object. You need RESPONSE to redirect, so if it isn't provided, you shouldn't redirect. Of course this needs to be documented and more reliable. Ahh. :) Is this work-in-progress by someone? ___ Zope-Dev maillist - [EMAIL PROTECTED] 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 )
Re: [Zope-dev] Re: [Zope] Optimization and speed
snip dicussion about large tables I take that back in the previous mail to Steve about the large table. We have one and I split the header from the rest as you suggested. But since it is not streaming the information, it will still pop up all at once. Any ideas? Steve just send me a file and a method but I do not understand what to get from it. I am checking the iste, whether I call RESPONSE.XXX somewhere in the middle of the page. Regards, Stephan PS: I contacted Illiad about an autogram and I will send the books to him to sign them and have the second one send back to you. Please send me your mailing address. -- Stephan Richter CBU - Physics and Chemistry Web2k - Web Design/Development Technical Project Management ___ Zope-Dev maillist - [EMAIL PROTECTED] 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 )
Re: [Zope-dev] Optimization and speed
Stephan Richter wrote: snip Method doc string Looks like it's more that just a tweak, though :-( So, how can I use this method? I do not understand the internals of the ZServer completely. You've got a RESPONSE object. For HTTP stuff, it will be a HTTPResponse as defined in lib/python/ZPublisher/HTTPResponse.py. You can use the write(self, data) method of this response object to stream data directly to your client, independent (to a degree) of Zope's transaction processing. This is the method from HTTPResponse. def write(self,data): """\ Return data as a stream HTML data may be returned using a stream-oriented interface. This allows the browser to display partial results while computation of a response to proceed. The published object should first set any output headers or cookies on the response object. Note that published objects must not generate any errors after beginning stream-oriented output. """ if not self._wrote: self.outputBody() self._wrote=1 self.stdout.flush() self.stdout.write(data) So, you could set output headers and cookies as needed, then, before the rest of the processing on your page, have a dtml-call "RESPONSE.write('the top of the page')". Then again, I've never tried this. YMMV and all that. (*off to help cook... won't be reading email for a while*) -- Steve Alexander Software Engineer Cat-Box limited http://www.cat-box.net ___ Zope-Dev maillist - [EMAIL PROTECTED] 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 )
Re: [Zope-dev] Optimization and speed
It looks like the pages you are serving are mostly big tables. Both Netscape and IE won't reder anything unless they got everything in the table. I would try to time the 'wget' speed to verify if zope is slow or not. Well, I kinda did that using telnet. I telneted into port 80 and then asked for an HTML page. I took about 3 secs (that's okay) for Zope to render the HTML page and then it bursted it out all at once. As I read from the other E-mails, Zope does not stream HTML to the HTTP Server till it is done laying out the site. That is the real problem. But the problem is still not solved. I am still 50% slower than other sites, even though Zope does not stream the data out. I played with the SQL Method cache; maybe I have to increase it more. Regards, Stephan -- Stephan Richter CBU - Physics and Chemistry Web2k - Web Design/Development Technical Project Management ___ Zope-Dev maillist - [EMAIL PROTECTED] 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 )
[Zope-dev] Optimization and speed
Hello everyone, I write this mail, because I could not find anything useful in the archives: I have a pretty big site with quiet a big database (PostGreSQL) in the background. When a site loads I can tell that after about 5 seconds the site is ready to download. The site downloads quickly thereafter if I am on a T1, DSL or Cable Modem connection. But since most of our users have 28.8k and 56k modem connection, we have to optimize for them too. When accessing the site over a modem, it takes a long time to load the site and then it pops up all at once (in IE (AOL) and Netscape). Is there a way that I can send parts of the HTML as it is generated, so that the customer starts seeing information before the entire site is loaded. Our site is about 50% slower than our competitors sites (we are serving 62kB and the competitor has up to 203kB and is 50% faster!!!) which use PHP and ColdFusion. I know that Zope is not slower. I strongly believe it is the HTML output which is not optimized (we are going to speed up the DB connection very soon by dedicating a NIC only for the DB communication). Technical Facts: - Zope 2.1.6+PCGI+Apache - Virtual Hosts for HTTP and HTTPS - PostGreSQL 7.0 (DB size: 50MB), ZPyGreSQLDA, UserDB - ZODB threads: 4 - Web Server: Pentium 500, RH 6.1, 322MB RAM (not all used), 100 MBit NIC - DB Server: Pentium 500, RH 6.1, 322MB RAM (plenty left to use), 100 MBit NIC - dedicated subnet If someone could give me some tips where I should start looking for speed holes, please let me know. Do you think it is the DB which could be so slow and I should cache search results more, are there ZServer/Apache options I can set or anything else in Zope I should have a look at? Regards, Stephan -- Stephan Richter CBU - Physics and Chemistry Web2k - Web Design/Development Technical Project Management ___ Zope-Dev maillist - [EMAIL PROTECTED] 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 )
[Zope-dev] Re: [Zope] Optimization and speed
On Sat, Jul 15, 2000 at 12:18:23PM -0700, Stephan Richter wrote: I have a pretty big site with quiet a big database (PostGreSQL) in the background. When a site loads I can tell that after about 5 seconds the site is ready to download. The site downloads quickly thereafter if I am on a T1, DSL or Cable Modem connection. But since most of our users have 28.8k and 56k modem connection, we have to optimize for them too. When accessing the site over a modem, it takes a long time to load the site and then it pops up all at once (in IE (AOL) and Netscape). Is there a way that I can send parts of the HTML as it is generated, so that the customer starts seeing information before the entire site is loaded. Our site is about 50% slower than our competitors sites (we are serving 62kB and the competitor has up to 203kB and is 50% faster!!!) which use PHP and ColdFusion. I know that Zope is not slower. I strongly believe it is the HTML output which is not optimized (we are going to speed up the DB connection very soon by dedicating a NIC only for the DB communication). Technical Facts: - Zope 2.1.6+PCGI+Apache - Virtual Hosts for HTTP and HTTPS - PostGreSQL 7.0 (DB size: 50MB), ZPyGreSQLDA, UserDB - ZODB threads: 4 - Web Server: Pentium 500, RH 6.1, 322MB RAM (not all used), 100 MBit NIC - DB Server: Pentium 500, RH 6.1, 322MB RAM (plenty left to use), 100 MBit NIC - dedicated subnet If someone could give me some tips where I should start looking for speed holes, please let me know. Do you think it is the DB which could be so slow and I should cache search results more, are there ZServer/Apache options I can set or anything else in Zope I should have a look at? Hi Stephan, This sounds like more of a HTML problem than a Zope problem, especially since the fast links have no trouble with the server. Zope obviously is fast enough to serve them. I bet your site heavily uses tables and images This will cause the browser to not display anything until it knows how to lay out the table. If your whole page is contained in one table, this means that your page won't pop up until the browser has seen the table end tag and knows the sizes of all images. You can help the browser a bit by making sure all IMG tags have a width and height attribute so the browser won't have to wait for the images to start to load. IIRC, Internet Explorer will even show the table without that information, and reflow the table if needed. It still will wait until it has the whole table. Only Mozilla reflows all incoming HTML on the fly, even before the end of the table is seen. When they the optimisations come in for Netscape 6 preview 3, it'll beat the hell out of Internet Explorer with this. So, if you want to make sure that your clients see something before all HTML is in, split up the table into a header and the rest, if possible. Then the browser has something to show while loading the rest of the page. This is what sites like www.cnet.com do; they show you a banner while waiting. -- Martijn Pieters | Software Engineermailto:[EMAIL PROTECTED] | Digital Creations http://www.digicool.com/ | Creators of Zope http://www.zope.org/ | ZopeStudio: http://www.zope.org/Products/ZopeStudio - ___ Zope-Dev maillist - [EMAIL PROTECTED] 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 )
Re: [Zope] Hot fix and 2.20
Hi! On Fri, Jul 14, 2000 at 08:19:14PM -0700, michael montagne wrote: Do I have this right? I do not have to install the hot fix if I just installed the recently released version 2.2.0 final. correct? yes, right! -- mr topf ___ 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] passing namespace
danchik wrote: if I submit a form to some page that has frames, how do I pass the REQUEST namespace to those frames Danchik, You've posted this question to the [EMAIL PROTECTED] list. This mailing list is about the technical internals of Zope, and developing new Zope products. Your question is more to do with using Zope as a web developer. You're more likely to get a useful response to your question if you post it to the [EMAIL PROTECTED] mailing list. I've cc-ed this message to that list instead of the zope-dev list. Also, I'd find it helpful to know what you have already tried, and what didn't work when you tried it. A simple example that demonstrates the problem would help too. Have you looked in the mailing list archives? Perhaps your question has already been answered there? Here's a link to a searchable archive. http://zope.nipltd.com/public/lists/zope-archive.nsf/ I searched just now for "request and frames", and there were a number of helpful-looking results. -- 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] Delete property woes in ZClasses
Hi Paul ! Paul Abrams wrote: I noticed that when you delete a property in a ZClass, it doesn't actually delete the property in **instances** of that ZClass! This leaves properties lying around where they can be inadvertently acquired, causing problems that are difficult to trace. Has anyone gotten bitten by this, or know of a solution? I solved it by adding this External Method, and calling all instances with it: #move_attribute?the_id=abstract def delete_attribute(self,the_id): self._delOb(the_id) BTW, I have also written an External Method that moves the attribute to a DTML Method: #move_attribute?the_attribute_id=abstract def move_attribute(self,the_attribute_id): attribute=str(getattr(self, the_attribute_id)) self._delOb(the_attribute_id) if attribute!="": self.manage_addDTMLMethod(the_attribute_id,file=" " + attribute) Regards, Maik Röder -- "The computing future is based on "cyberbodies" - self-contained, neatly-ordered, beautifully-laid-out collections of information, like immaculate giant gardens." The second coming - A manifesto. David Gelernter http://www.edge.org/3rd_culture/gelernter/gelernter_p1.html ___ 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] 2.2.0 and Membership ... NoGo
Bill Anderson wrote: Dunno what changed, but in 2.2.0b4 I could use Membership w/the latest ZPatterns just fine. In 2.2.0 when I try to add one, I get: "keyword redefined" errors. Phillip has already made a fix to ZPatterns that corrects the call to the product factory. It's in alpha 5. Shane ___ 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] Zope + Apache on FreeBSD 4.0 problems
Hi John, There are no 'tricks' that I am aware of... for 'straight' Zope. Some 3rd party products may require modules that are not in the 'default' Python port, but that's easily fixed... I'm running Zope 2.1.6 on several FreeBSD 4.0s boxen. Can you be a little more specific about the error? thanks, -steve "jholland" == jholland [EMAIL PROTECTED] writes: jholland I'm having trouble getting pcgi working for Zope 2.16 on jholland Apache 1.3.12 on FreeBSD 4.0. I had hope the BSd ports jholland would set it up but it seems that there is a problem of jholland some sort with my install. jholland Zope.cgi produces output but kind of maimed. jholland I did get Zope.cgi working with IIS and NT (ugh) at jholland work. jholland Any tricks or anything would be appreciated. jholland John Holland - --- jholland Email: [EMAIL PROTECTED] Web: jholland http://jbhsoft.linuxave.net Public key : finger -s or jholland http://jbhsoft.linuxave.net/pubkey.html jholland -BEGIN PGP SIGNATURE- Version: PGP 6.5.2 jholland iQA/AwUBOW/O7RPWCCE2yAKHEQIO1ACg9ZqBAVcnICmKG4m7UH4lYIqigbwAn3U6 jholland ylPYJcO5GBP+hCSvARxRzZuc =RakZ -END PGP jholland SIGNATURE- jholland ___ Zope jholland maillist - [EMAIL PROTECTED] jholland http://lists.zope.org/mailman/listinfo/zope ** No cross jholland posts or HTML encoding! ** (Related lists - jholland http://lists.zope.org/mailman/listinfo/zope-announce jholland http://lists.zope.org/mailman/listinfo/zope-dev ) ___ 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] ZPygres connection problem
Hello! I did an experiment (after having problems connecting Zope to Postgres) - I stopped ZServer and restared Zope in PCGI-only mode. I opened connection successfully! I stopped PCGI and restarted ZServer. I again got BadRequest (cannot connect to server). Anyone have an idea why Zope+ZServer cannot connect, while Zope-PCGI can? Deeper investigation did not reveal any difference - environments are the same, I can connect from command line, I can even import DB.py (from the Database Adapter) and connect through it from command line... Oleg.(All opinions are mine and not of my employer) Oleg Broytmann Foundation for Effective Policies [EMAIL PROTECTED] Programmers don't die, they just GOSUB without RETURN. ___ 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] Cannot install PTK
Hi, I installed Zope2.2.0 and downloaded PTK0.7.1, installed it, restarted Zope and then tried to import DemoPortal.zexp, but after pressing import an error message is shown and there is no PTKBase or PTKDemo in the Available Objects ... Any ideas? Mario ___ 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] Hot fix and 2.20
I think so... Chris michael montagne wrote: Do I have this right? I do not have to install the hot fix if I just installed the recently released version 2.2.0 final. correct? -mjm Name: winmail.dat winmail.datType: application/x-unknown-content-type-dat_auto_file Encoding: base64 ___ 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] Cannot install PTK
Mario Premke wrote: I installed Zope2.2.0 and downloaded PTK0.7.1, installed it, restarted Zope and then tried to import I think the 0.7.1 snapshot release is a little out of date ;-) Check the latest version out of the CVS or try Kevin Dangoor's much more recent snapshot: http://www.zope.org/Members/taz/PTK cheers, Chris ___ 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] Hot fix and 2.20
Do I have this right? I do not have to install the hot fix if I just installed the recently released version 2.2.0 final. correct? -mjm That is correct - the hotfix is only required for sites running versions prior to 2.2. Brian Lloyd[EMAIL PROTECTED] Software Engineer 540.371.6909 Digital Creations http://www.digicool.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] Zope build script
Hello! I've published a simple shell script I use to compile Zope from sources and configure it a bit: http://www.zope.org/Members/phd/build-zope/ The simple script does: -- compiles *.py files to *.pyc -- runs python w_pcgi.py -- runs python zpasswd.py access -- generates root.sh - a script to run under root to complete the installation; root.sh set up right ownership and permissions in the installation tree You can easily customize it to your needs. Oleg. Oleg Broytmann http://www.zope.org/Members/phd/ [EMAIL PROTECTED] Programmers don't die, they just GOSUB without RETURN. ___ 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] sending namespace to the frames?
danchik wrote: if I submit a form to some page that has frames, how do I pass the REQUEST namespace to those frames You can't, I think you need to look into the way frames work more carefully or word your question differently. Also, please don't post to both [EMAIL PROTECTED] and [EMAIL PROTECTED] as it may irritate the large number of people who are subscribed to both ;-) cheers, Chris ___ 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] Zope + Apache on FreeBSD 4.0 problems
On 15 Jul, [EMAIL PROTECTED] wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 I think it's something about the port. Actually it was only pcgi I was having trouble with; however with Apache rewrite I see that is not necessary though although I got it working anyway. Do you mind sharing which "something about the port" failed for you and how you got it working. I'm the maintainer for that port. The port should be working pretty much out of the box... -Th ___ 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] load_site stopped working in 2.2.0
Hi! I've got the error: File "./lib/python/ZPublisher/Client.py", line 221, in __call__ bci.NotAvailable: argument 1: expected read-only character buffer, tuple found (File: http://sun.med.ru/pcgi/manage_addFolder Line: id=HomePage.local) None None for None What's this? Oleg.(All opinions are mine and not of my employer) Oleg Broytmann Foundation for Effective Policies [EMAIL PROTECTED] Programmers don't die, they just GOSUB without RETURN. ___ 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] ZStylesheet
Warning: This is a 'get it off my chest' e-mail. Well, I am going to give up with CSS. I am sure ZStylesheet is a fine product, its just that CSS implementations lets it down. I have struggled for ages to get anything more sophisticated than font-family* to work on both IE5 and Netscape 4.6 - no chance. It seems they have both implemented CSS from a different hymn sheet :-( Basically, nothing to do with sizes works the same, and it boils down to Netscape ignoring the inheritance model of CSS. table rows and cells are a particular mystery. If anyone has cracked it and has developed a ZStylesheet which can second guess both browsers, please let me know. Until then, I will go back to using font size="12pt" or whatever. Shame, but I have more interesting things to worry about. Regards Neil *even font-family doesn't work for the BODY selector. Tables in Netscape ignore it so you have to use BODY TR TD as the selector. ___ 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] ZStylesheet
On Sat, Jul 15, 2000 at 09:40:58PM +0200, Neil Burnett wrote: Warning: This is a 'get it off my chest' e-mail. Well, I am going to give up with CSS. I am sure ZStylesheet is a fine product, its just that CSS implementations lets it down. I have struggled for ages to get anything more sophisticated than font-family* to work on both IE5 and Netscape 4.6 - no chance. It seems they have both implemented CSS from a different hymn sheet :-( Basically, nothing to do with sizes works the same, and it boils down to Netscape ignoring the inheritance model of CSS. table rows and cells are a particular mystery. If anyone has cracked it and has developed a ZStylesheet which can second guess both browsers, please let me know. Until then, I will go back to using font size="12pt" or whatever. Shame, but I have more interesting things to worry about. CSS in current 4.x and IE 5 is a nightmare. There are lobying groups you can join, like the web standard initiative. Mozilla does an excellent job of fully implementing CSS1, and practically all of CSS2 as well. Opera also has a good stab at it, all the test pages list that as a good 2nd. Until Netscape 6 is out (based on Moz), don't count on CSS being all that useful. -- Martijn Pieters | Software Engineermailto:[EMAIL PROTECTED] | Digital Creations http://www.digicool.com/ | Creators of Zope http://www.zope.org/ | ZopeStudio: http://www.zope.org/Products/ZopeStudio - ___ 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] Zope build script
Martijn Pieters wrote: On Sat, Jul 15, 2000 at 03:13:46PM +, Oleg Broytmann wrote: On Sat, 15 Jul 2000, Martijn Pieters wrote: The simple script does: -- compiles *.py files to *.pyc w_pcgi.py and wo_pcgi.py do this as well. Then they changed since I looked last time. I remember they didn't compile *.py... w_pcgi.py imports and runs wo_pcgi.py, which in turn imports inst/compilezpy.py. The act of importing that file causes it to compile all .py files from the Zope directory and all it's subdirectories. YUp, and you can cerify it by installing products in the Products tree, and running w_pcgi.py or wo_pcgi.py and watch them compile the produtcs and sometimes spit out syntax errors in them... Bill -- Do not meddle in the affairs of sysadmins, for they are easy to annoy, and have the root password. ___ 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] 2.2.0 and Membership ... NoGo
Shane Hathaway wrote: Bill Anderson wrote: Dunno what changed, but in 2.2.0b4 I could use Membership w/the latest ZPatterns just fine. In 2.2.0 when I try to add one, I get: "keyword redefined" errors. Phillip has already made a fix to ZPatterns that corrects the call to the product factory. It's in alpha 5. h maybe I'll reinstall beta5 ... That's what I was using when I got this. -- Do not meddle in the affairs of sysadmins, for they are easy to annoy, and have the root password. ___ 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] hard dtml syntax problem
Jerome Alet wrote: On Thu, 13 Jul 2000, Bill Anderson wrote: Jerome Alet wrote: Hi want to call ZopeFind to find all folders in the current folder which doesn't have got any subfolder. Sorry, I should have added : recursively !!! Ahh, big difference! :-) [...] From a Folder, I want to recursively search for all "terminal" folders (leaves) and build a list of these folders. bye "terminal" folder, I mean a folder with no subfolder. The following should give me exactly the result I want, if only I knew how to write it in a way accepted by the dtml parser: dtml-let myresult="ZopeFind(this(), obj_metatypes=['Folder'], search_sub=1, obj_expr=""" not objectValues(['Folder']) """ )" ... /dtml-let My actual solution is to do : dtml-let myresult="ZopeFind(this(), obj_metatypes=['Folder'], search_sub=1)" dtml-if "not objectValues(['Folder'])" ... /dtml-if /dtml-let but this solution is not good because if I need len(myresult) it returns me the total number of folders, not the number of "terminal" folders, and I find it stupid to have to build a new list in a dtml-in and then loop over the new list in a second dtml-in because I know ZopeFind is the solution: can do it, I've tested it with the Find tab. My only problem is: What is that f... syntax ? Personally, something like this I would do in python. IMO, deep recursion belongs in python,not DTML. -- Do not meddle in the affairs of sysadmins, for they are easy to annoy, and have the root password. ___ 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] pcgi not responding ...2.2
Works fine from ZServer (on port 8101), butpcgi gets: """ pcgi-wrapper(/home/ZSS/libc/Zope.cgi): Connection refused (102) failure during connect to ZServer """ Ideas welcome. -- Do not meddle in the affairs of sysadmins, for they are easy to annoy, and have the root password. ___ 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] ZStylesheet
Hi Neil ! Neil Burnett wrote: Warning: This is a 'get it off my chest' e-mail. Well, I am going to give up with CSS. I am sure ZStylesheet is a fine product, its just that CSS implementations lets it down. Well, perhaps you can have a look at the Web Designers Portal under the subject Stype and Topic CSS. http://zdp.zope.org/portals/webdesigners/style/css There are some good reasons for CSS, that I have collected there. Maybe you can also have a look at the link, which you can find there to Webreview.com's CSS Master Compatibility Chart. Best regards, Maik Röder -- "The computing future is based on "cyberbodies" - self-contained, neatly-ordered, beautifully-laid-out collections of information, like immaculate giant gardens." The second coming - A manifesto. David Gelernter http://www.edge.org/3rd_culture/gelernter/gelernter_p1.html ___ 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] Delete property woes in ZClasses
Hi Paul ! Paul Abrams wrote: Thanks! I think the delete method will be ideal to patch my site. I also see how the move method can be *very* useful. Shall I write this up as a how-to? That would be great ! Perhaps you can also find a way to do this recursively ? Have a look at my recursive copier: http://zdp.zope.org/projects/zsnippet/snippets/DTMLTags/recursive_copier This does it the other way around, but it can be adopted to do what you need. It would be handy if you have many instances floating around. Maybe you can also do it easier with a ZCatalog search ? Best regards, Maik Röder -- "The computing future is based on "cyberbodies" - self-contained, neatly-ordered, beautifully-laid-out collections of information, like immaculate giant gardens." The second coming - A manifesto. David Gelernter http://www.edge.org/3rd_culture/gelernter/gelernter_p1.html ___ 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] ZStylesheet
try http://www.w3.org/StyleSheets/Core/ dont give up on css yet! frankly i woudnt even worry about netscape 4.x, Regards, GEORGE DONNELLY [EMAIL PROTECTED] http://cyklotron.com/ The one who tells the stories rules the world. --Hopi proverb Warning: This is a 'get it off my chest' e-mail. Well, I am going to give up with CSS. I am sure ZStylesheet is a fine product, its just that CSS implementations lets it down. I have struggled for ages to get anything more sophisticated than font-family* to work on both IE5 and Netscape 4.6 - no chance. It seems they have both implemented CSS from a different hymn sheet :-( Basically, nothing to do with sizes works the same, and it boils down to Netscape ignoring the inheritance model of CSS. table rows and cells are a particular mystery. If anyone has cracked it and has developed a ZStylesheet which can second guess both browsers, please let me know. Until then, I will go back to using font size="12pt" or whatever. Shame, but I have more interesting things to worry about. Regards Neil *even font-family doesn't work for the BODY selector. Tables in Netscape ignore it so you have to use BODY TR TD as the selector. ___ 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] Optimization and speed
Hello everyone, I write this mail, because I could not find anything useful in the archives: I have a pretty big site with quiet a big database (PostGreSQL) in the background. When a site loads I can tell that after about 5 seconds the site is ready to download. The site downloads quickly thereafter if I am on a T1, DSL or Cable Modem connection. But since most of our users have 28.8k and 56k modem connection, we have to optimize for them too. When accessing the site over a modem, it takes a long time to load the site and then it pops up all at once (in IE (AOL) and Netscape). Is there a way that I can send parts of the HTML as it is generated, so that the customer starts seeing information before the entire site is loaded. Our site is about 50% slower than our competitors sites (we are serving 62kB and the competitor has up to 203kB and is 50% faster!!!) which use PHP and ColdFusion. I know that Zope is not slower. I strongly believe it is the HTML output which is not optimized (we are going to speed up the DB connection very soon by dedicating a NIC only for the DB communication). Technical Facts: - Zope 2.1.6+PCGI+Apache - Virtual Hosts for HTTP and HTTPS - PostGreSQL 7.0 (DB size: 50MB), ZPyGreSQLDA, UserDB - ZODB threads: 4 - Web Server: Pentium 500, RH 6.1, 322MB RAM (not all used), 100 MBit NIC - DB Server: Pentium 500, RH 6.1, 322MB RAM (plenty left to use), 100 MBit NIC - dedicated subnet If someone could give me some tips where I should start looking for speed holes, please let me know. Do you think it is the DB which could be so slow and I should cache search results more, are there ZServer/Apache options I can set or anything else in Zope I should have a look at? Regards, Stephan -- Stephan Richter CBU - Physics and Chemistry Web2k - Web Design/Development Technical Project Management ___ 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] Optimization and speed
On Sat, Jul 15, 2000 at 12:18:23PM -0700, Stephan Richter wrote: I have a pretty big site with quiet a big database (PostGreSQL) in the background. When a site loads I can tell that after about 5 seconds the site is ready to download. The site downloads quickly thereafter if I am on a T1, DSL or Cable Modem connection. But since most of our users have 28.8k and 56k modem connection, we have to optimize for them too. When accessing the site over a modem, it takes a long time to load the site and then it pops up all at once (in IE (AOL) and Netscape). Is there a way that I can send parts of the HTML as it is generated, so that the customer starts seeing information before the entire site is loaded. Our site is about 50% slower than our competitors sites (we are serving 62kB and the competitor has up to 203kB and is 50% faster!!!) which use PHP and ColdFusion. I know that Zope is not slower. I strongly believe it is the HTML output which is not optimized (we are going to speed up the DB connection very soon by dedicating a NIC only for the DB communication). Technical Facts: - Zope 2.1.6+PCGI+Apache - Virtual Hosts for HTTP and HTTPS - PostGreSQL 7.0 (DB size: 50MB), ZPyGreSQLDA, UserDB - ZODB threads: 4 - Web Server: Pentium 500, RH 6.1, 322MB RAM (not all used), 100 MBit NIC - DB Server: Pentium 500, RH 6.1, 322MB RAM (plenty left to use), 100 MBit NIC - dedicated subnet If someone could give me some tips where I should start looking for speed holes, please let me know. Do you think it is the DB which could be so slow and I should cache search results more, are there ZServer/Apache options I can set or anything else in Zope I should have a look at? Hi Stephan, This sounds like more of a HTML problem than a Zope problem, especially since the fast links have no trouble with the server. Zope obviously is fast enough to serve them. I bet your site heavily uses tables and images This will cause the browser to not display anything until it knows how to lay out the table. If your whole page is contained in one table, this means that your page won't pop up until the browser has seen the table end tag and knows the sizes of all images. You can help the browser a bit by making sure all IMG tags have a width and height attribute so the browser won't have to wait for the images to start to load. IIRC, Internet Explorer will even show the table without that information, and reflow the table if needed. It still will wait until it has the whole table. Only Mozilla reflows all incoming HTML on the fly, even before the end of the table is seen. When they the optimisations come in for Netscape 6 preview 3, it'll beat the hell out of Internet Explorer with this. So, if you want to make sure that your clients see something before all HTML is in, split up the table into a header and the rest, if possible. Then the browser has something to show while loading the rest of the page. This is what sites like www.cnet.com do; they show you a banner while waiting. -- Martijn Pieters | Software Engineermailto:[EMAIL PROTECTED] | Digital Creations http://www.digicool.com/ | Creators of Zope http://www.zope.org/ | ZopeStudio: http://www.zope.org/Products/ZopeStudio - ___ 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 )