Re: [Zope] AJAX and Zope

2006-05-24 Thread Greg Fischer

The one thing I have found about Ajax and Zope (Ajax and anything
really) is that your returned scripts are typically so customized to
your web page DOM and your application logic.  So, as someone else
posted, Zope handles everything in it's own separate objects anyway,
so no need for a special server side processing system.  This is just
my limited experience though.

I found it was just as easy to use Dojo Toolkit and my plain old DTML
objects on Zope2 for my app server.  You could just as easily use PT
and Python scripts.  Have a look at this site I did as a demo last
fall.

http://www.zajax.net

I was first asking the same things you were.  I wanted a library or
some other way to handle the Ajax calls, but found it was so simple to
just use Dojo and let it do asynchronous calls to Zope DTML objects.
What I have is uber simple, but that's all I wanted.

I can't remember if in that demo I returned javascripts or html, but I
do know that with Dojo you can do either one.  I built another small
Ajax app later, and it does return javascripts. (very fast updates
that way)



On 5/24/06, Pascal Peregrina [EMAIL PROTECTED] wrote:

By Zope objects I meant:

You've got a page template for example, and you include such an AJAX enabled 
object, basically rendering an HTML fragment, and the resulting page will include 
the page template code + the fragment (similar to a macro call), but will also include 
the needed javascript code to handle the asynchronous communication.

Then another thing would be something like a PythonScript object (so you define 
python code and return python structures) and get it rendered as javascript to 
be included in somepage for processing the data returned by an asynchronous 
XML-RPC call to Zope within the browser.

Does it make more sense now?

Pascal

-Message d'origine-
De: Lennart Regebro [mailto:[EMAIL PROTECTED]
Envoyé: mercredi 24 mai 2006 14:56
Ŕ: Pascal Peregrina
Cc: zope@zope.org
Objet: Re: [Zope] AJAX and Zope

On 5/24/06, Pascal Peregrina [EMAIL PROTECTED] wrote:
 I was wondering if there is any plan to have built-in support (i.e.
 helpers, built-in Zope objects, etc) in order to support AJAX in Zope at
 some point.

The helpers would then be some sort of Ajax JS library. I think that
at this time it makes more sense to let people choose for themselves.
If one turns out to be better than the others, it will spread around
the community and become a default standard, and then maybe it's
interesting to include as a standard package, but thats a big maybe
and a big if.

I don't know what any built-in Zope-objects would do for Ajax. :)

--
Lennart Regebro, Nuxeo http://www.nuxeo.com/
CPS Content Management http://www.cps-project.org/


**
This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
the system manager.

This footnote also confirms that this email message has been swept by
MIMEsweeper for the presence of computer viruses.

www.mimesweeper.com
**
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )




--
Greg Fischer
1st Byte Solutions
http://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] exUserFolder Product Install Problems in Windows XP

2006-01-24 Thread Greg Fischer
Well this is no help, butI havent tried in 6 months, however last time I did, I was not able to run exUserFolder on Zope 2.8.x. It was working fine on 2.7.x though. I never did find what the problem was, and my issue probably has nothing to do with yours, but I thought it was worth mentioning in case it did. Does it work for you in 
2.7? Kind of a hassle to test, but if it works, maybe it will help in troubleshooting?GregOn 1/23/06, José Carlos Senciales 
[EMAIL PROTECTED] wrote:HelloI have downloaded the exUserFolder Product and copy the folder into my
directory Products of Zope butwhen restar my zope i found this error:: File C:\Archivos deprograma\Zope-2.8.4-final\lib\python\Products\exUserFolder\AuthSources\etcAuthSource\etcAuthSource.py
,line 124, in ?from Products.exUserFolder.fcrypt.fcrypt import cryptImportError: No module named fcrypt.fcryptanyone know why this is happening? . there is a folder CryptoSources whitthe module fcrypt into, in the exUserFolder Product folder.
I have install Zope 2.8.4-final, python 2.3.5, win32I´m working in Windows XP SP2.Thanks.___Zope maillist-
Zope@zope.orghttp://mail.zope.org/mailman/listinfo/zope** No cross posts or HTML encoding!**(Related lists - 
http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )-- 
Greg Fischer1st Byte Solutionshttp://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] TinyMCE

2006-01-23 Thread Greg Fischer
Yes, that would rock! I just started using TinyMCE a few months back, it works beautifully. It's a little bulky, but you can slim it down with less features needed. Having an integrated Zope product with this would be wonderful. I hope you follow through with that!
GregOn 1/23/06, Peter Bengtsson [EMAIL PROTECTED] wrote:
Hi all,Are there any open source efforts in integrating TinyMCE with Zopesimilar to Kupu?If not, I might actually give it a go.--Peter Bengtsson,work www.fry-it.com
home www.peterbe.comhobby www.issuetrackerproduct.com___Zope maillist-
Zope@zope.orghttp://mail.zope.org/mailman/listinfo/zope** No cross posts or HTML encoding!**(Related lists - 
http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev
 )-- Greg Fischer1st Byte Solutionshttp://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] MySql 5.0, ZMySQLDA and stored procedures

2006-01-17 Thread Greg Fischer
Yeah, I put up a patch on the MySQLDb Sourceforge page a long time ago for that. Doing almost the same thing. Only I made it so you specify the client flag in the Zope connection object. Doesnt do any good for windows though, they still have a problem with the mysql lib. (I think I posted a bug on that too)
GregOn 1/16/06, Cameron Beattie [EMAIL PROTECTED] wrote:
I was getting the following error when attempting to call a stored procedurevia a Z SQL Method:_mysql_exceptions.OperationalError: (1312, etcSo I made the following change to/usr/lib/zope/lib/python/Products/ZMySQLDA/db.py:
def _parse_connection_string(self, connection):kwargs = {'conv': self.conv, 'client_flag': 65536 #inserted by CSB }I then restarted Zope. I can now successfully call stored procedures. There
may be a better way to do it. Feel free to advise if so.Apologies if this information has already been posted.Cameron___Zope maillist-
Zope@zope.orghttp://mail.zope.org/mailman/listinfo/zope** No cross posts or HTML encoding!**(Related lists - 
http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )-- 
Greg Fischer1st Byte Solutionshttp://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] Leave the ivory tower now!

2006-01-16 Thread Greg Fischer
I took part in an old thread from here from several months ago:http://www.gossamer-threads.com/lists/zope/users/184052?do=post_view_threaded
In there, some of the prominent members from this list came up with some great points on the DTML vs ZPT thing. All great stuff. However, I agree with you. While some of the ZPT fans say that DTML is broke and it sucks, and from there perspective it might, for some of us DTML is great and we have no desire to use ZPT. For us, DTML is not broke.
I like what you said, be tolerant. Some of us don't see the limitations of DTML as something that is broken, or that it is not good. I don't think there is anything wrong with ZPT either, I simply don't have a use for it. Coexist? Yes, I hope they always do.
Personally, I am doing more and more with PHP. There are multiple reasons for that, but partly it is due to a conception in the Zope community that DTML is bad, and as such, it might go away. The *hype* is all about ZPT, not DTML. I don't want to pursue a development platform that is a foundation of my applications on something that is going away, or even hinting to it. That might not be the case, might be totally false. But we cant deny the fact that if there is no hype, then there is no attention to it, and less people will use it and even less will support it.
Now don't get me wrong about that last paragraph, I LOVE ZOPE! It just does things so easily that other environments have to struggle with. (Acquisition being one of them. Which also is something that people say is broke in some ways. It does do weird things sometimes. But if you know how to deal with them... ;)
I hope my opinions are of help to others. (just remember, these are just my opinions, to those to might be ready to slam me for them. I intend no offense.)GregOn 1/16/06, 
garry [EMAIL PROTECTED] wrote:
Nicolas Georgakopoulos wrote: Rakotomandimby Mihamina wrote: On Mon, 2006-01-09 at 14:29 +0100, Garito wrote: I thing DTML and ZClasses will disapear someday
 You think, I hope :-) I beg ;-). ___Can someone explain why there is a continual battle between those who
like dtml and those who like zpt?Surely the two can co-exist and then individual developers can choosewhich most suits them. Neither seems to be broken and both provide avalid experience for users, so let's be tolerant. :-)
regardsGarry___Zope maillist-Zope@zope.orghttp://mail.zope.org/mailman/listinfo/zope
** No cross posts or HTML encoding!**(Related lists - http://mail.zope.org/mailman/listinfo/zope-announce 
http://mail.zope.org/mailman/listinfo/zope-dev )-- Greg Fischer1st Byte Solutionshttp://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] Leave the ivory tower now!

2006-01-16 Thread Greg Fischer
>From Tino: --No matter if DTML is still there (and it will) we shouldfind better ways to teach people how to easy develope inZope.--Yes, you are right on all you mention. I didn't know PT was available in other environments/languages. Interesting. However, I still don't want to use them. Doesn't mean that someday I wont find a need and desire for it though. 
The reason I don't use PT is because I can do what I want without it. You mention that better ways to teach is needed, and you are right about that, but when someone like me has no desire to learn it, then it wont help. Worth noting though, I have looked at it briefly, and it confused the hell out of me. So, you may be right on anyway, because if it were explained in a such a way that caused me to just *get it*, then maybe I would go that route. 
I guess it's really a matter of, do I want to spend the time to learn something when I am loaded with other things to learn all the time, and why fix it if it isnt broke? (broke from my perspective ,that is.)
Well, why can't there also be good training on DTML as well? (actually, I don't thinks it's all that bad anyway.) And, like Gary asked, why can't there be a peaceful coexistence bewteen the ZPT and DTML fans? The reason why I ask? Because there is commonley someone saying *DTML sucks, use PT* when users ask questions about DTML. (maybe not in those words, but you get the idea.) 
I don't know. I do appreciate your responses and thoughts Tino. (as you have always done for me in the past)GregOn 1/16/06, Tino Wildenhain
 [EMAIL PROTECTED] wrote:Greg Fischer schrieb:
... I like what you said, be tolerant.Some of us don't see the limitations of DTML as something that is broken, or that it is not good.I don'tI see we have to improve teaching. think there is anything wrong with ZPT either, I simply don't have a use
 for it.Coexist? Yes, I hope they always do. Personally, I am doing more and more with PHP.There are multiple reasons for that, but partly it is due to a conception in the Zope community that DTML is bad, and as such, it might go away. The *hype* is
 all about ZPT, not DTML.I don't want to pursue a development platformYou can have PT with PHP too. Thats the cool part about it. Its reallykinda standard. You have PT for Zope, PHP, Perl, Java, ...
 that is a foundation of my applications on something that is going away, or even hinting to it.That might not be the case, might be totally false.But we cant deny the fact that if there is no hype, then there
 is no attention to it, and less people will use it and even less will support it.I dont think thats the problem. I saw even weirder frameworksto work with. I guess we could introduce an even suckier template
language and people would fall in love with it.BTW: ZPT is not, and was never a replacement for DTML.DTML would be replaced by application logic in pythonor python scripts and ZPT together.No matter if DTML is still there (and it will) we should
find better ways to teach people how to easy develope inZope.++Tino-- Greg Fischer1st Byte Solutionshttp://www.1stbyte.com

___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] Leave the ivory tower now!

2006-01-08 Thread Greg Fischer
Yes, we need hype! And a hot looking site, WITH Web 2.0 features. Many of these frameworks are providing AJAX capabilities, simple graphics and data/object access without page reloads. (like I am using with Dojo right now) What does Zope not provide these features built-in?
And yes, about the central docs. A ton of info is available right on Zope.org, but I always find more on individual blogs or other google searches. Zope.org
 could use a more intuitive help finder maybe. Actually, how aboot a Zopedigg? Diggs on just Zope articles and such, with comments? That would be hot! Better and easier than a wiki, IMHO. The one thing I would say is, from my perspective, when I have info to share on Zope work I have done, I like to post on my blog or site, not Zope's. Because I like to provide a demo or maybe include things *my* way. Having a ZopeDigg would allow us to post our work in a central repository, and look a little flashy too.
The video tutorial should be made. Like RoR and Symfony-project have. It shows beginners how easy something is to do. And they will download it. I did. Also, I know this will get some people flaming probably, but Zope needs more hype for DTML. I KNOW! 99% of you hate it. But every time I show someone how to do it, their eyes light up. It's very simple coming from ASP or PHP, once you see it in action. ZPT is just plain confusing to me. I hate to say this too, but I am doing much more in PHP these days, partly due to the fact that there exists a large dtml sucks attitude in the community. And even though it has been said that DTML is not going away, if there is no hype about it, then it might. And I don't want to keep using Zope without it. Yes, yes, I know DTML has many disadvantages, but it also has many advantages. I wish there were more hype about it. 
So, here's a big wish of mine too. What if Zope was a *complete* framework, including a web based IDE? I dont mean the ZMI, which is hot in itself, but a full featured AJAX-ish IDE, built upon Zope. Drag and drop widgets and properties even. It would also have full database access built in. Mysql, Mssql, Oracle, Postgresql, all ready to go, without needing to purchase and configure a database adapter. This would provide a web based, development framework like .NET using Visual Studio. Only this would work on Zope, and therefore would run on Linux OR Windows! It doesnt have to be so comprehensive like VS, but simple form editor with properties and XMLHTTPRequest capability would be great. I think we would have a KILLER APP!
Well, maybe I am dreamin? Just thought I'd give my 2 cents.Oh, and is the community growing? Well, I think the Netcraft surveys say a lot. I know this isnt definitive, but I think it's great info. Since I started using Zope in 2002, the sites using Zope have grown from 6000 to 42000. Cool!
42000+ Sites in 2006http://survey.netcraft.com/Reports/0601/6000+ Sites in 2002http://survey.netcraft.com/Reports/0201/
Happy new year everyone!On 1/3/06, Jonathan Cyr [EMAIL PROTECTED] wrote:



  


Do we know Is the Zope
community growing or shrinking? Is there even a problem? Is Python
growing or shrinking? Is there any connection? 

Zope.org seems to have been built as a community center, with accounts/
3rd party add-ons etc. Is it working. RubyonRails.com has none of
this functionality.

Perhaps a GetZope.com site, similar to GetFirefox.com is in order, that
provides a very small amount of get started information.

Two Cents,

-Jon

Gert Thiel wrote:

  Dear friends.A few days ago the Ruby on Rails development team published the 1.0 release.At that occasion the Zope fans are reminded how far Zope fell far behind interms of attention and recognized widespread.
Python has batteries included. Zope is a power plant. But still everyonespeaks of Django, Turbogears or Ruby on Rails. Even if they talk about theshortcommings of J2EE.Some of the best content management systems are build using Zope 2. CPS, ZMS
and my favourite: Plone. And Typo3 gets even more attention. Why?Because we failed. We aren't marketing Zope at all. Have a look at 
zope.org.Do you think, that any CEO will stay at that site more than 10 seconds? Havea look at rubyonrails.org
 and cry. Zope 3.2 will be delivered soon. Have anylook at zope.org ‹ where isŠ You got it.To a certain extent Zope 2 was attracting like a nuclear power plant.
Whenever I start programming with Zope 2, latest for Plone, I can feel itspower before even diving into it much, but I'm alarmed of its pitfalls atthe very same time. So all my hopes are with Zope 3 which enabled me without
hurting me yet. Will I get a truly powerful replacement for J2EE?Here are my ideas to make Zope 3 the most successful framework ever:Make them love Zope at the very first look:* Make installing Zope a double-click or one-command-only experience and
* offer a 30 minutes tutorial of programming an useful application  including an audiovisual show for an appetizer that offers a feeling  of 

Re: [Zope] Re: Re: ZAjax anyone?

2005-10-11 Thread Greg Fischer
Ah even better! Thanks guys.

I was going to reply just to mention I have a not as cool way of using Zope with Ajax at my site now too.

www.zajax.net

Seems every rock I turn over, I find 3 others worth
investigating. Lots of cool stuff going on out there. I put
up my own demo, but it's not nearly the prefered way of doing things by
most people. I myself, prefer DTML over ZPT, so my demo is based
on that. I also am using one of the larger client frameworks
available, Dojo Toolkit. The js file is around 130k if I
remember. The smaller ones are great and do the job, but I wanted
something larger and more widely used like Dojo to build off of.

I know eventually I'll look at the JSON stuff too. Sound interesting.

GregOn 10/11/05, Balazs Ree [EMAIL PROTECTED] wrote:
On Mon, 10 Oct 2005 23:28:03 +0800 Bakhtiar A Hamid wrote: we have zope (dtml/script/zsql-method) that do specific calls that spits out results via xmlrpc. on the browser side, we have all these ajax libs - openrico, dojo,
 mochikits, azax, DataRequestor, jsolait, tim morgan's mini, etc we just need to connect the dots. the ajax lib + our java functions/etc will call dtml/script/sql-method via xmlrpc(builtin) or jasonrpc(with the
 jsonrpc product) and page will be updated inline(?) not much voodo involved. everything is there already. a simple demo is at 
http://myzope.kedai.com.my/blogs/kedai/demo/; a script python that just spits out DateTime().pCommon(), and the other, a script python tah calls html file randomly. replace that with anythin we want.
 zope rox! but i guess we all know thatThanks, this was a nice briefing.I like the demos, and as a single additional comment I would add that forjson-rpc I myself too made some (although more crude looking) simple
demos, that do not have a live server but that are installable: so thatyou can start playing with it on your own server and modify any client orserver scripts, if you install the demo + jsonserver2 into Zope as two
individual products.Downloads:http://www.zope.org/Members/ree/jsonserver2_pkg/Guide for the demos:
http://www.zope.org/Members/ree/jsonserver2_exa--Balazs Ree___Zope maillist-Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope** No cross posts or HTML encoding!**(Related lists - http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )-- Greg Fischer1st Byte Solutions
http://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] Re: Re: ZAjax anyone?

2005-10-11 Thread Greg Fischer
Jim,

I am more than happy to take contributions from others. Using
other libs or maybe even just some Zope techniques in general is
great. Right now, I just loaded that stuff up over the last few
days, so it's quite limited. But, if you have anything you would
like to share, please zip it up and email it over to me. Just put
together all the html for the body, I'll post it for ya, with credit to
you of course.

I am sure that if I get a bunch of other how-tos to post, I will
probably have to grow things a bit, but it will evolve over time.
All of this stuff is a learning process for me, so I wanted to put up
that site to share my experiences in hopes that others could benefit.

Zope 3, I would love to put stuff up for that, but I havent even
touched Zope 3 yet. I am more than happy to put of info on that
as well. 

Thanks!

GregOn 10/11/05, Jim Washington [EMAIL PROTECTED] wrote:
Greg Fischer wrote: Ah even better!Thanks guys. I was going to reply just to mention I have a not as cool way of using Zope with Ajax at my site now too. 
www.zajax.net http://www.zajax.net/ Seems every rock I turn over, I find 3 others worth investigating. Lots of cool stuff going on out there.I put up my own demo, but it's
 not nearly the prefered way of doing things by most people.I myself, prefer DTML over ZPT, so my demo is based on that.I also am using one of the larger client frameworks available, Dojo Toolkit.The js
 file is around 130k if I remember.The smaller ones are great and do the job, but I wanted something larger and more widely used like Dojo to build off of. I know eventually I'll look at the JSON stuff too.Sound interesting.
Hi, GregCool!I like the way you do the how-to.Do you plan similar how-tosfor other JS libraries/techniques?Would you accept contributions? Ifind myself looking at mochikit (
http://mochikit.com) occasionally.Inits ajax-tables demo, it uses a tal(esque) syntax for dom manipulationin client _javascript_, which could be interesting for fans of page templates.For the future, dare I ask, maybe some zope3 stuff?
I think the zope community really needs zope-oriented how-tos andevaluations of the various AJAX libraries.zajax.net has the right nameto be a prime focus of such activities, should you be willing to do that.
Thanks!-Jim Washington-- Greg Fischer1st Byte Solutionshttp://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] Re: ZAjax anyone?

2005-10-09 Thread Greg Fischer
Thank you everyone! I really appreciate all the input. It's
amazing what you find by doing a little more thorough
searching... here's more of what I am looking for: 
http://timmorgan.org/wiki/ReactFrameworkForZope

Tim Morgan has put together what I would call Zajax from the looks of
it. I am going to start playing around with it, and see how it
fits my needs.

On a side note, I have put together a quick 'n' dirty blog about the
things I am finding, particularly for XMLHTTP, not JSON or
XML-RPC. www.zajax.net - (I liked the name so much, I had
to register the domain! :)On 10/9/05, Michael Haubenwallner [EMAIL PROTECTED] wrote:
Chris McDonough wrote: On Oct 8, 2005, at 6:54 AM, Greg Fischer wrote: I would love to have a product (called ZAjax :) that simplyreceives a request from the client and spits out xml.To be morespecific, a
 set of classes that call ZSQL methods and retrieverecords, then send that back in xml format. We've had this built in to Zope for a long time in the form of XML- RPC.There are several _javascript_ libraries that implement an XML- RPC
 client, the best in my recollection being vcXMLRPC.http://myzope.kedai.com.my/blogs/kedai/49shows a few different ways to do Ajax and Zope.
Michael--http://zope.org/Members/d2mhttp://planetzope.org___Zope maillist-
Zope@zope.orghttp://mail.zope.org/mailman/listinfo/zope** No cross posts or HTML encoding!**(Related lists - 
http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev
 )-- Greg Fischer1st Byte Solutionshttp://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] Re: ZAjax anyone?

2005-10-09 Thread Greg Fischer
Ok, after further investigation, Tim Morgan's React is not exactly what
I am looking for. That said, his work is outstanding, and I think
it's awesome! It's like Ruby On Rails implemented (better IMHO)
in Zope! Very cool!

However, I think what I want to work with is just a Zope product without the MVC stuff. 

Thanks again everyone!

GregOn 10/9/05, Greg Fischer [EMAIL PROTECTED] wrote:
Thank you everyone! I really appreciate all the input. It's
amazing what you find by doing a little more thorough
searching... here's more of what I am looking for: 
http://timmorgan.org/wiki/ReactFrameworkForZope

Tim Morgan has put together what I would call Zajax from the looks of
it. I am going to start playing around with it, and see how it
fits my needs.

On a side note, I have put together a quick 'n' dirty blog about the
things I am finding, particularly for XMLHTTP, not JSON or
XML-RPC. www.zajax.net - (I liked the name so much, I had
to register the domain! :)On 10/9/05, Michael Haubenwallner 
[EMAIL PROTECTED] wrote:
Chris McDonough wrote: On Oct 8, 2005, at 6:54 AM, Greg Fischer wrote: I would love to have a product (called ZAjax :) that simplyreceives a request from the client and spits out xml.To be morespecific, a
 set of classes that call ZSQL methods and retrieverecords, then send that back in xml format. We've had this built in to Zope for a long time in the form of XML- RPC.There are several _javascript_ libraries that implement an XML- RPC
 client, the best in my recollection being vcXMLRPC.http://myzope.kedai.com.my/blogs/kedai/49
shows a few different ways to do Ajax and Zope.
Michael--http://zope.org/Members/d2m
http://planetzope.org___Zope maillist-
Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope** No cross posts or HTML encoding!**(Related lists - 
http://mail.zope.org/mailman/listinfo/zope-announce 
http://mail.zope.org/mailman/listinfo/zope-dev
 )-- Greg Fischer1st Byte Solutions
http://www.1stbyte.com

-- Greg Fischer1st Byte Solutionshttp://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


[Zope] ZAjax anyone?

2005-10-08 Thread Greg Fischer
So I have been reading and learning a lot the last couple days about
this whole AJAX thing. I really think it is something I am going
to move towards for web apps. However, I don't want to lose Zope.
I wonder if any of you would be willing to comment on this?

I quickly tested Ruby on Rails, given all it's hype lately. It's
a nice setup, but I kept using it thinking, I can do that in DTML
quite easy. I just don't have the XMLHttpRequest going, or the
_javascript_ client libraries that make the interface improvements.
The tutorials I followed mentioned that you have this nice recipe app
in a half hour. I thought again, So, I can do that in a half
hour in Zope. It's not the speed that appealing, it's the
XMLHTTP requests without page reloads that is appealing. If I can
just do this in Zope, wow! (There were some things in Rails that
I liked, like the whole Model/Controller/View thing. But, really,
we could implement that type of scenareo in Zope apps too, I would
think.)

I did it. (at a very simple/small level) Though it's not
automated like in Rails, but it's not that hard. I used
Prototype.js and Rico.js for the Ajax client libs. Then I simply
setup a generic/non-css Rolodex page like the one for Rico
http://openrico.org/rico/demos.page?demo=ricoAjaxInnerHTML.html
>From here, I made a simple DTML Method, getPersonInfo.xml. It had
DTML to check for request objects passed in from the Rolodex ajax
objects, and then send back the particular record. Pretty simple,
but quite an eye opener for me.

It really got me thinking. We need, for those of us who would
like to pursue this development, a Zope/Ajax backend. There's a
bunch of others for PHP, .NET, and whatever else. We need
ZAjax! 

I would love to have a product (called ZAjax :) that simply receives a
request from the client and spits out xml. To be more specific, a
set of classes that call ZSQL methods and retrieve records, then send
that back in xml format. Maybe make it so, in my client script, I
can call the python class with arguments of, zsql method name, zsql
method args. Doing it this way would keep things database
platform independent. (more so than Rails) Also, it would give
you control of the SQL, and make our table space indiferent to the
python or client engine. And, it would still keep it simple, or
at least, not really any more complicated than doing zpt or dtml.
IMHO. What do you guys think?

One of the things that bugged me about Rails was the fact that you have
to name your table primary keys id. And you have to call them a
plural name. (like contacts) And in the ruby code, you
refer to your classes singularly. (contact) Plus, foreign keys
had to be named, othertable_id. This whole thing really messed me up,
and turned me off to it. Then, I found out that using stored
procedures was shunned upon. LOL! Yeah right! I can
totally see the arguments they have though, but to me it's a matter of
preference. I like sprocs for certain things, whether or not I am
using a whole new style of web programming. And, I love
Zope. Can't do without it.

So, after reading all that, I have on last thought. Is it really
best to even use Zope in an AJAX-style application? Maybe it's
best to use mod-python in Apache? And if I am doing that, then
there's always DJango. Well, for me, I have a hunch, that at some
point the ability to use your Ajax app with the existing ZODB (and all
the other Zope niceties) will be huge benefit and a powerful platform.

OMG, long email...

I am going to spend a little more time practicing this new development
and testing it. Probably I will move to script.aculo.us for the
extension to prototype.js because of the nice interface elements.
However, I don't know how to build a Zope product yet. So, if there's
nothing available in the next few months, I guess I'll start working on
it. (IF I decide it really is best to stick with Zope, which I think it
is.) BTW, I know about the Json thing too, but I prefer to stick
with same methods and objects already used, like prototype. (used by
Rails) 

Is there an sql to xml product for zope that would do this already? 

Thanks for listening... and I'll have more to say.
Greg
-- Greg Fischer1st Byte Solutionshttp://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] ZAjax anyone?

2005-10-08 Thread Greg Fischer
Oh, that's cool! The naming RPC threw me off. I knew that
was there, but I guess my assumptions (I know , bad) were that it
communicated over a different protocol, not using port 80. But, I
suppose, tcp over port 80, spewing out xml is good. Probably just
what I need. I'll look into that and get a better
understanding. Thanks Chris.

GregOn 10/8/05, Chris McDonough [EMAIL PROTECTED] wrote:
On Oct 8, 2005, at 6:54 AM, Greg Fischer wrote: I would love to have a product (called ZAjax :) that simply receives a request from the client and spits out xml.To be more specific, a set of classes that call ZSQL methods and retrieve
 records, then send that back in xml format.We've had this built in to Zope for a long time in the form of XML-RPC.There are several _javascript_ libraries that implement an XML-RPC client, the best in my recollection being vcXMLRPC.
- C-- Greg Fischer1st Byte Solutionshttp://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


[Zope] Re: Mysql 5? Just curious.

2005-10-07 Thread Greg Fischer
Oh, just read a little better... wanted to clarify...

 It doesnt work with stored procedures though. I put a patch up on sourceforge in July, for the ZMySQLDA. 

Mysql-python works fine fine, as you said Andy, it's just the Zope DA.

Greg

(I hate it when reply-all doesnt send to zope list too)On 10/7/05, Greg Fischer [EMAIL PROTECTED] wrote:
It doesnt work with stored procedures though. I put a patch up on sourceforge in July, for the ZMySQLDA.


http://sourceforge.net/tracker/index.php?func=detailaid=1242842group_id=22307atid=374934



I probably didnt do it right, but I at least wanted to get the info up
there. (maybe should have listed a bug?) MySQLdb works fine
directly from python, but the DA doesnt open a connection with the
right client_flags. It needs MULTI_STATEMENTS.

I just added this to db.py in _parse_connection_string, right before it parses the socket. (line 234, I think)


if not items: return kwargs

kwargs['client_flag'], items = int(items[0]), items[1:]

One caveat, you must use a dash to turn off transactions. I don't
know why that is, or how to get around it. But, with that patch,
and a connection string like the one below, it works great!

 
-adatabase auser apassword 65536 /tmp/mysql.sock

I just wanted to specify the client_flags before the socket.
Before you couldnt specify them at all. On Linux this was fine,
but on Windows, if memory serves, the mysql.c had some issues. Maybe
needs compiled with new libs?

Anyway, like I said on that patch post, there is probably a better way
to tackle the issue. I just did it this way, and it works for me.
Though, the transaction thing needs attention.

Greg

On 10/7/05, Andy Dustman [EMAIL PROTECTED]
 wrote:
On 10/7/05, Tres Seaver [EMAIL PROTECTED] wrote: Greg Fischer wrote:  I guess it's not a matter of should, but rather a preference. I am running
  it just fine on Linux. Had to do some tweeks to the ZMySQLDA, but it works  great. Stored Procedures and everything. I just havent seen hardly anyone  testing it, so I thought I would ask around and see if others are running it
  too. Cool.Could you send the patches for your tweaks to the ZMySQLDA maintainer (Andy Dustman, I believe)?Maybe it would be better to upload them to the SourceForge patches page:
I've done a small amount of testing with MySQLdb-1.2.0 and MySQL-5.0,and there don't seem to be any issues, so ZMySQLDA-2.0.9 (latest beta)ought to work as well. There is a bugfix that needs to be applied (for
the tried to unlock unlocked lock issue), but this should already bein the bug tracker on sourceforge.--Computer interfaces should never be made of meat.

http://www.terrybisson.com/meat.html-- Greg Fischer1st Byte Solutions
http://www.1stbyte.com

-- Greg Fischer1st Byte Solutionshttp://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] How to make a table with sortable colmns?

2005-10-07 Thread Greg Fischer
There is the sort attribute of the dtml-in tag. You'll have to read the DTML Reference for more info on that.

However, it was a little iffy for me once, and now I do something like this:

1. Setup table header with a response back to sort that column.
2. Change the ZSQL method to use that value dynamically.

Maybe not the best/most efficient way, but it works great for my use.

So on your table header, either add forms with submit links, or add a
link with query strings. I usually add a query string, so my
table header looks like this:
tr
 tda href="" URL0?sortby=colACol A/td
 tda href="" URL0?sortby=colBCol B/td
/tr
Then in your ZSQL method, setup an argument for sortby. Make
sure you name colA or colB exactly like your table columns. In
the method, I create a dtml-if at the end of the query:
Select 
dtml-if _.has_key('sortby')
 Order by dtml-var sortby, LastName
dtml-else
 Order by LastName
/dtml-if

OR

Select 

dtml-if _.has_key('sortby')

 Order by dtml-var sortby

/dtml-if

I have LastName there because I always wanted that column to be a
second sort. You obviously would have a different one.  There's
probably a little more to this I am not thinking of at the moment, but
I hope it helps you towards your goal. You could also get real
fancy and add ascending and descending to the mix. (click to sort,
click again to sort desc)

Greg

On 10/7/05, Thomas Apostolou [EMAIL PROTECTED] wrote:
Hello all,i am using the following to get some data fromDatabaseand show them in a table:headMETA HTTP-EQUIV=Content-Type CONTENT=text/html;charset=ISO-8859-7
/headstyle type=text/css media=screen!-- @importurl(/plone.css); --/stylestyle type=text/css media=screen!-- @import
url(/ploneColumns.css); --/stylestyle type=text/css media=all!-- @importurl(/ploneCustom.css); --/styledtml-var standard_html_headertable id=sortable class=listing summary=Content
listing cellpadding=0 cellspacing=0theaddtml-in expr=GetHeader(sysDSN=sysDSN, usr=usr,mypass=mypass, sTable=sTable)th class=
dtml-in sequence-itemdtml-var sequence-item/dtml-in/th/dtml-in/theaddtml-in expr=GetData(sysDSN=sysDSN, usr=usr,
mypass=mypass, sTable=sTable)dtml-if sequence-eventr class=evendtml-elsetr class=odd/dtml-if
dtml-in sequence-item!--td input type=checkbox title=dtml-varsequence-item /td--tddtml-var sequence-item/td
/dtml-in/tr/dtml-in/tabledtml-var standard_html_footerBut how can i tell the table to sort the column iclick on just like plone does with the members list?
Thanks in advanceThomas Apostolou___Χρησιμοποιείτε Yahoo!;Βαρεθήκατε τα ενοχλητικά μηνύματα (spam); Το Yahoo! Mail
διαθέτει την καλύτερη δυνατή προστασία κατά των ενοχλητικώνμηνυμάτων http://login.yahoo.com/config/mail?.intl=gr___
Zope maillist-Zope@zope.orghttp://mail.zope.org/mailman/listinfo/zope** No cross posts or HTML encoding!**
(Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev
 )-- Greg Fischer1st Byte Solutionshttp://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] external editor

2005-10-07 Thread Greg Fischer
I have the same prob. Crimson Editor wont do it when using
tabs. You have to specify to open multiple instances in the
Crimson preferences. Then it works fine.

GregOn 10/7/05, Garry Saddington [EMAIL PROTECTED] wrote:
Peter Bengtsson wrote:You are missing something. I can edit multiple objects with bothdreamweaver and xjed.PS. I don't _use_ dreamweaver but I need to test it sometimes for clients :)
2005/10/7, Garry Saddington [EMAIL PROTECTED]:I do not seem to be able to edit more than one file at a time in an
external editor. Is this normal behaviour or am I missing something?regardsGarry___Zope maillist-
Zope@zope.orghttp://mail.zope.org/mailman/listinfo/zope** No cross posts or HTML encoding!**(Related lists - 
http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev
 )--Peter Bengtsson,work www.fry-it.comhome www.peterbe.com
hobby www.issuetrackerproduct.comHave you had two documents in one instance of an editor (eg tabs) ormultiple instances of the same editor? I have tried Oxygen, Crimson
editor and Boxer all on XP and all with tabs for the differentdocuments. The first opened doc can be saved but any others are not saved.regardsGarry___
Zope maillist-Zope@zope.orghttp://mail.zope.org/mailman/listinfo/zope** No cross posts or HTML encoding!**(Related lists -
 http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev
 )-- Greg Fischer1st Byte Solutionshttp://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


[Zope] Mysql 5? Just curious.

2005-10-04 Thread Greg Fischer
This is totally unimportant, but I was just curious to know if anyone is running Mysql 5 on Zope right now.
-- Greg Fischer1st Byte Solutionshttp://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists - 
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] dtml-if

2005-08-28 Thread Greg Fischer
I have never been able to do that either and always wondered how to do
it.  However I have a workaround that I use frequently.  I just use
the title instead, which works perfectly.

dtml-if title == 'My Page' This one!/dtml-if

Greg


On 8/28/05, michael [EMAIL PROTECTED] wrote:
 What am I doing wrong here?
 
 dtml-var last -- this prints out the variable sent from last
 (referring) page fine
 dtml-var id -- this prints out the id of the current item fine
 
 
 dtml-if id == last  this one!  /dtml-if
 
 i want this to output this one! when the current item is the one
 requested by the last page but they are never seen as == even when the
 two dtml-var are the same
 
 they are never equal!
 
 
 thanks,
 mike
 
 
 ___
 Zope maillist  -  Zope@zope.org
 http://mail.zope.org/mailman/listinfo/zope
 **   No cross posts or HTML encoding!  **
 (Related lists -
  http://mail.zope.org/mailman/listinfo/zope-announce
  http://mail.zope.org/mailman/listinfo/zope-dev )
 


-- 
Greg Fischer
1st Byte Solutions
http://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] Re: Zope Foundation Update

2005-07-22 Thread Greg Fischer
HAHAHHAHA!!! LOL!

Man!  There has got to be some humor in this at some point!

Honestly, though, I appreciate your discussions being held here.  I
truly appreciate the fact that I have Zope to work with and offer to
my customers.  I feel that I owe that thanks not only to Zope
Corporation, but to the community as well.  I just wanted to chime in
from a tiny part of the *silent majority* so that both parties hear
it.  I love Zope, we all do.  Work this out. :-)

Greg

On 7/21/05, Lennart Regebro [EMAIL PROTECTED] wrote:
 ZC: Potay-to.
 ZEA: Potah-to.
 ZC: Potay-to!
 ZEA: Potah-to!
 ZC: Potay-to!!
 ZEA: Potah-to!!
 ZC: POTAY-TO, you evil thief!!!
 ZEA: POTAH-TO you dictatiorial pig!!
 
 Not a communications problem? My ass.
 ___
 Zope maillist  -  Zope@zope.org
 http://mail.zope.org/mailman/listinfo/zope
 **   No cross posts or HTML encoding!  **
 (Related lists -
  http://mail.zope.org/mailman/listinfo/zope-announce
  http://mail.zope.org/mailman/listinfo/zope-dev )
 


-- 
Greg Fischer
1st Byte Solutions
http://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] Problem with ZSQLMethods/MySQL after update

2005-06-28 Thread Greg Fischer
I could be totally wrong, but just a thought

You might remove the Zmysqlda 2.0.8 you have and download and install
the 2.0.9b3.  Do some reading before, and maybe you can simply
reinstall 2.0.8.  I cant remember what it was that needed 2.0.9, maybe
it was just having mysqlpython 1.2.0.  (because of mysql 4.1.x or new
python, cant remember)

Ok I am just thinking outloud now, sorry.  But heck, if it helps. :)

Greg

On 6/28/05, Dieter Maurer [EMAIL PROTECTED] wrote:
 Ragnar Beer wrote at 2005-6-27 18:50 +0200:
 After upgrading Zope from version 2.6.4 to 2.8.0 and mysqlpython from 0.9.2 
 to
 1.2.0 I cannot add or edit ZSQLMethods anymore, although there is an open
 (MySQL)db-Connection that works just fine with the same ZSQLMethods that 
 cannot
 be edited or with external methods. The error I'm getting is:
 
 There are no SQL database connections. You need to add a Zope SQL database
 connection before you can edit a Zope SQL Method.
 
 Almost surely, your ZMySQLDA instances are broken (and then
 do not behave as SQL database connection instances).
 
 Check your Zope logfile for messages of the form
 could not install product
 
 --
 Dieter
 ___
 Zope maillist  -  Zope@zope.org
 http://mail.zope.org/mailman/listinfo/zope
 **   No cross posts or HTML encoding!  **
 (Related lists -
  http://mail.zope.org/mailman/listinfo/zope-announce
  http://mail.zope.org/mailman/listinfo/zope-dev )
 


-- 
Greg Fischer
1st Byte Solutions
http://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] Python Scripts

2005-06-16 Thread Greg Fischer
Yeah, I do see that every once in a while.  I have a very simple
script, that looks perfect, but will always return syntax error.  I
copied the text, pasted into a text editor and checked all the indents
and tabs, then recreated the script.  Problem went away.

What was interesting is that I didnt change the code.  And even
thought the indents were the same, re-adding them might have solved
it.  Dont know for sure, but I dont see this enough to cause me
problems.

Greg

On 6/16/05, J Cameron Cooper [EMAIL PROTECTED] wrote:
  We have been seeing a number of instances where python scripts fail
  due to an apparent syntax error but the syntax is correct and simply
  storing the method restores it to functionality.   Anyone else seeing
  this?
 
 How do you mean fail?
 
 Often times, if you have an error, save, test, and then use the back
 button, you'll see the old syntax error, even though the contents are
 the new (and correct) version.
 
 If you just revisit the script (click on the id in the breadcrumbs) the
 message will go away.
 
 --jcc
 --
 Building Websites with Plone
 http://plonebook.packtpub.com
 ___
 Zope maillist  -  Zope@zope.org
 http://mail.zope.org/mailman/listinfo/zope
 **   No cross posts or HTML encoding!  **
 (Related lists -
  http://mail.zope.org/mailman/listinfo/zope-announce
  http://mail.zope.org/mailman/listinfo/zope-dev )
 


-- 
Greg Fischer
1st Byte Solutions
http://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] recommend a provider

2005-06-06 Thread Greg Fischer
I've been using Zettai.net for a while now and they've been pretty
good. They've got all the basic stuff for minimal cost on the Shared
plans.  You can go with freezope.org, but I havent tried them, plus
they have a bunch of limitations being a free service.  At Zettai you
get Mysql or Postgresql and on the Shared plans all the products are
setup so you just start up and start working.

While I like Zettai, I have recently started using Unixshell.com and
will be moving all my hosting there eventually. However, you have to
be able to do *all* your own Linux mangement.  For me it's great
because of the full control I get (for cheap), but it might not be
good for newbies.  Unixshell.com is not a Zope hosting provider, they
are a VPS service, so you can run your own Zope server.  (BTW, they
are using Xen virtualization, and I am totally impressed!)

My 2 cents.
Greg

On 6/3/05, Dave Kuhlman [EMAIL PROTECTED] wrote:
 On Fri, Jun 03, 2005 at 08:13:15AM -0400, fs1 wrote:
  Can someone recommend a zope enabled internet provider?
  Frank
 
 Here are several you can look into:
 
 - http://www.objectis.org/
 
 - http://www.zettai.net/
 
 - http://www.python-hosting.com/
 
 Which is right for you depends on what capabilities your need:
 
 - High volume?
 
 - Access to the ZMI?
 
 - Ability to install Zope Products?
 
 - Ability to implement external methods?
 
 - Access to a relational database?
 
 - Etc.
 
 Some Zope hosting providers offer a range of plans at different
 costs and with different capabilities.
 
 And, you can also look in this list of resources:
 
 http://www.zope.org/Resources/ZSP
 
 Also, of course, do a search for zope hosting in your favorite
 Web search tool.
 
 Dave
 
 --
 Dave Kuhlman
 http://www.rexx.com/~dkuhlman
 ___
 Zope maillist  -  Zope@zope.org
 http://mail.zope.org/mailman/listinfo/zope
 **   No cross posts or HTML encoding!  **
 (Related lists -
  http://mail.zope.org/mailman/listinfo/zope-announce
  http://mail.zope.org/mailman/listinfo/zope-dev )
 


-- 
Greg Fischer
1st Byte Solutions
http://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] recommend a provider

2005-06-06 Thread Greg Fischer
I have the 64 MB account and I run Apache, Mysql, Firebird, and Zope.
(plus Courier mail)  If I run only apache, Zope, and Mysql, 64 MB
worked fine, but with mail and Firebird it's running about 20MB on the
swap now.  Of course, I setup Debian on it and omitted everything from
running that didnt need to be there.  Even tweeked Apache the best I
could to limit processes, but it's working great for me.

The only disadvantage to running Unixshell.com is that you are on your
own as far as management goes.  You have to do all the security and
setup yourself.  But they have this kick ass installer from the web
that sets up an image from your fav distro.  It's pretty sweet if you
like the control and dont mind spending the time to setup everything.

A big advantage that they have is, for a VPS solution, you arent
docked for running over your memory.  See, if I go to 80MB, it just
used some swap.  It's just like I had my own server with a fixed
amount of ram.  If I went with other VPS solutions, I would be charged
for using more memory.  And since I dont know what resources I might
need, that wouldnt work.

I've never ran Plone, so I dont know what is involved or what kind of
resource you would need.  I have a low traffic setup, but I have one
client that runs a billing/customer tracking Zope/mysql app with 4
users on it all day and I havent had any trouble. Best I can say is,
try it for a month.  It's only $15 - $20 to see if it will fit your
needs.

If you decide to go with them, send me an email and I'll give you a
few tips to get started as I was really confused at first.  (regarding
the remote console and ssh)  It's very cool what they have going, but
it's unmanaged and you have to be willing to run it yourself.  (they
manage the hardware and netowrk of course.)

On the other hand, Zettai.net has been great for me too.  I think they
have separate Plone hosting from their Zope hosting now.  They have
been very reliable and have good support.  Plus you dont have to do
any setup on the server itself, so you can be running quickly.  But,
again, if you like the total control, the Unixshell.com rocks.

Greg


On 6/6/05, Parra [EMAIL PROTECTED] wrote:
 Greg,
 
 I saw their website, and average plan gives 96 to 256 of RAM.
 If you install Plone, isn't a little amount of RAM ?
 
 Thanks
 
 Marcello
 
  While I like Zettai, I have recently started using Unixshell.com and
  will be moving all my hosting there eventually. However, you have to
  be able to do *all* your own Linux mangement.  For me it's great
  because of the full control I get (for cheap), but it might not be
  good for newbies.  Unixshell.com is not a Zope hosting provider, they
  are a VPS service, so you can run your own Zope server.  (BTW, they
  are using Xen virtualization, and I am totally impressed!)
 
 ___
 Zope maillist  -  Zope@zope.org
 http://mail.zope.org/mailman/listinfo/zope
 **   No cross posts or HTML encoding!  **
 (Related lists -
  http://mail.zope.org/mailman/listinfo/zope-announce
  http://mail.zope.org/mailman/listinfo/zope-dev )
 


-- 
Greg Fischer
1st Byte Solutions
http://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] DTML in Zope 2 vs Zope 3

2005-05-27 Thread Greg Fischer
Wow, thanks for the replies guys.  It's good to hear I am not the only
one who likes DTML.

Tino, thanks for the explanations.  I have some thoughts below on
that, and keep in mind, I am questioning from my own ignorance.

Tino Wrote:
 The major drawbacks of DTML are:
 
 - one namespace (with transparent layers)  
One namespace?  Why do you need more?  I havent had any problems with
one.  Can you give some examples of why this is important or how it
would be useful?

 - confusing naming of tags, like dtml-var which
   really is dtml-print or something
Well I realize that it could be named something else, but it never
occured to me.  I dont think it's confusing.  I mean, in DTML you use
4 tags more than any other, IN, VAR, IF, and CALL.  Simple.  And if
there is one thing I have learned over the few years I have been
programming, it is to keep it simple. Simple works.

 - and the extra tags for flow control, but probably
   the dtml fans can live with it.
Yeah, simple.  We can live with it, particularly since we can call
more detailed functionality from Python.

 - peoples practice to use dtml-var foo even inside
   html-tags attributes, where dtml-foo; should be used.
Hmm.. Never thought of that one as I too just use the full dtml-var
foo.  I can see now that it might make readability a little better to
use dtml, but is there a technical reason for using it that way?

Thank you again for your input Tino.  I can understand the need to
take Zope to another level, its the nature of things to keep them
growing.  And changing Zope to fit the needs of large scale
applications is good, I just hate to see the sacrifice of the smaller
apps needs.  I probably will never get to work on enterprise class
systems, in fact I really dont want to, but Zope works beautifully for
the small web apps and that's what I want to work on.  I wonder what
the ratio is of Zope users who use small apps to those who do large
apps?

Thanks again!

Greg

On 5/26/05, Tino Wildenhain [EMAIL PROTECTED] wrote:
 Am Freitag, den 27.05.2005, 00:20 +0200 schrieb Jaroslav Lukesh:
 ...
  I absolutelly agree with you, it is like my words.
 
  But separation of logic and presentation could be done successfully in DTML
  too. ZPT, which have separation argument is not as easy to make totally
 
 This is even somewhat correct. If people had the discipline to not abuse
 the templating to do complicated logic.
 The major drawbacks of DTML are:
 
 - one namespace (with transparent layers)
 - confusing naming of tags, like dtml-var which
   really is dtml-print or something
 - and the extra tags for flow control, but probably
   the dtml fans can live with it.
 - peoples practice to use dtml-var foo even inside
   html-tags attributes, where dtml-foo; should be used.
 
  separated design as marketing says, for example see Plone - try to customize
  plone site to absolutelly different custom design - it is near impossible.
 
 Unfortunately Plone is still a bad example for ZPT. It is getting
 better but still it has a lot of code and definition in the templates.
 Maybe AT would be a way out.
 
 ___
 Zope maillist  -  Zope@zope.org
 http://mail.zope.org/mailman/listinfo/zope
 **   No cross posts or HTML encoding!  **
 (Related lists -
  http://mail.zope.org/mailman/listinfo/zope-announce
  http://mail.zope.org/mailman/listinfo/zope-dev )
 


-- 
Greg Fischer
1st Byte Solutions
http://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] DTML in Zope 2 vs Zope 3

2005-05-27 Thread Greg Fischer
Using DTML from WYSIWYG editors is definitely a drawback.  But, how
many of us use them for doing our work?  I might use Dreamweaver to
clean up my sliced web template, but soon as I start my Zope work,
it's all Crimson Editor coding by hand to Zope.  Using Dreamweaver
actually slows me down, it's easier to just code it.  However, from a
newbie perspective, not being able to run my Zope content in my fancy,
drag'n'drop editor really bugged me a long time a go.

Saying DTML sucks is only stating your difference of oppinion.  At
least give us some insight as to why it sucks.  Technical, usability,
or even marketing reasons would be helpful.  But, come on DUH? 
Everybody will have their preference of languages, and even the way
they like to layout the code.  So I understand that some of us like
DTML and some dont.

All that aside, DTML may be ugly, but I dont agree.  I guess beauty is
in the eye of the beholder. :)

Well, aside from the fact that you cant use DTML in WYSIWYG editors, I
still dont understand why it is not good.  If it is simple, easy to
use, and it does the job, and I suppose, if you prefer it, why is it
not good to use?

I've beaten this subject to death, so time to move on.
Thanks for hearing me out.
Greg

On 5/27/05, Lennart Regebro [EMAIL PROTECTED] wrote:
 On 5/26/05, Greg Fischer [EMAIL PROTECTED] wrote:
  Is DTML really that much harder to use?
 
 Nah, but it's uglier. Also, the idea is that a web editor that
 confirms to the tsandard of ignoring things it doens't understand,
 should in theory be usable with TAL, but not with DTML. In practice,
 however, HTML editors don't do that.
 
  I understand the whole idea of separating the logic and the
  presentation, and I guess, is that part of the reason why DTML is not
  as good?
 
 Well, it used to be. But logic crept into ZPTs as well. The good thing
 is to set up all the data in a python script or python method, and
 then use the template only to display this data. Zope3 has this
 separation built-in, when you create a page with a template it
 automatically gets connected to a view which is a python class, and
 you can specify your own custom view and set up the data there.
 
 In Zope 2 you have to call a script that creates the data, or
 reversely, use the script as the main view and let it call the
 template. (I don't know how easy that last thing is with DTML, but the
 first one works).
 
 If you do this, the drawbacks of DTML becomes much less painful.
 --
 Lennart Regebro, Nuxeo http://www.nuxeo.com/
 CPS Content Management http://www.cps-project.org/
 


-- 
Greg Fischer
1st Byte Solutions
http://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] DTML in Zope 2 vs Zope 3

2005-05-27 Thread Greg Fischer
Ah you are right.  Just occured to me.  That is kind of a pain in
DTML, but I've learned how to deal with it.  Makes sense.

If I already have an object, say from a form submitted, in the REQUEST
namespace, and I then retrieve data from sql and a column has the same
name, I will have an issue.  Which one is going to display in my var?

I deal with this particular issue by changing my zsql method to return
the column name differently, but there are other times when this may
arise and it is a problem. And this causes you to have to do a bunch
of messy dtml-call REQUEST.set's to set your vars correctly.

I have learned how to deal with these things, but you are right, this
is a problem with DTML and I can see how this exact issue helps make
DTML messy and a little confusing.  Great point.  Thanks.

Greg

On 5/27/05, Lennart Regebro [EMAIL PROTECTED] wrote:
 On 5/27/05, Greg Fischer [EMAIL PROTECTED] wrote:
  Well, aside from the fact that you cant use DTML in WYSIWYG editors, I
  still dont understand why it is not good.
 
 Well, the fact that you get everyting directly into the current
 namespace, especially with DTML-in, and things like that, is the real
 problem. But as noted, by making all data-gathering in a python
 script, the problems with this are less and survivable.
 
 --
 Lennart Regebro, Nuxeo http://www.nuxeo.com/
 CPS Content Management http://www.cps-project.org/
 


-- 
Greg Fischer
1st Byte Solutions
http://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] DTML in Zope 2 vs Zope 3

2005-05-26 Thread Greg Fischer
I am just curious, why is DTML not good?  It does 9 out of 10 things I
want quite easily.  From my perspective, I really dont want to learn
new ways of doing things if this works.  I also have no desire to do
templating.  I can see the need for it in a large development shop,but
for me, a 1 guy operation, I have no desire to complicate things. 
DTML works so easy for me.

I do use Python scripts here and there for small and odd things that
would be difficult or impossible to do in DTML, but like I said,
that's maybe only 10% max of the functionality that I need to provide.
(probably 5-6%) Having to move everything in Python is a hassle that I
dont plan on doing for a few years.  I'll just keep using Zope 2.

I'd also be curious to know from all you other developers, what
percentage of tasks that you need to perform or functionality you need
to provide can be provided simply with DTML?  Like for me, I can do
quickly and easily do 90% of what I need in DTML.

Is DTML really that much harder to use?

I understand the whole idea of separating the logic and the
presentation, and I guess, is that part of the reason why DTML is not
as good?  But, for me, that separation is more complicated.  DTML is
easier for me.  (partly because I know it)

I dont know, DTML and the everythings an object concept in Zope are
the very things that make Zope so attractive for a small time operator
like me.  I hate to see them deprecated just because it doesnt work
for the larger companies out there.  Of course, I may be totally
ignorant about all this, huh?

Anyway, starting to ramble...  Thanks for any thoughts.
Greg

On 5/26/05, Hugo Ramos [EMAIL PROTECTED] wrote:
 Yellow,
 
 I have the same feeling... Python should be the primary language used
 in Zope but let's not just cut the support on DTML leaving thousands
 out there spinning around and having to go into Python as fast as they
 can because DTML is not supported anymore.
 Changes take time... Getting used to Python only in Zope takes time...
 and I'm not so sure the employers out there are that kind allowing
 everybody to take time making the move.
 
 
 Regards
 Hugo
 
 
 On 5/26/05, David H [EMAIL PROTECTED] wrote:
  Hugo Ramos wrote:
 
  Yellow,
  
  I think because of lazy people like me that prefer to use DTML in a
  fast way than go into a deep Python level to get the job done...
  I know that, eventually, one of these days I'll have to move on to
  Python only but until that day comes... DTML and a little bit of
  Python where needed suits me fine! :-)
  
  Regards
  Hugo
  
  
  
  Hugo,
  I figured as a dtml wiz a few years ago.  Now I can't image doing
  w/out python scripts and suddenly DTML gives me a headache.  I do think
  that DTML deserves a Hall of Fame Award but its time to move on.
 
  David
 
 
 
 
 
 
 --
 Hugo Ramos - [EMAIL PROTECTED]
 ___
 Zope maillist  -  Zope@zope.org
 http://mail.zope.org/mailman/listinfo/zope
 **   No cross posts or HTML encoding!  **
 (Related lists -
  http://mail.zope.org/mailman/listinfo/zope-announce
  http://mail.zope.org/mailman/listinfo/zope-dev )
 


-- 
Greg Fischer
1st Byte Solutions
http://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] dollars-and-cents display fails

2005-05-14 Thread Greg Fischer
http://dev.mysql.com/doc/mysql/en/numeric-type-overview.html
That's it right there!  Before 5.0.3, they were unpacked, meaning
saved like a char.  Now they are packed, fixed point numbers.  This is
screwing up the python functions for fmt.

Well, I was trying to NOT redo all that code, but looks like I will
have to if I want to run the new mysql.  I have tons of reports using
dtml and fmt.   I think I'll stick with 5.0.0 for now until I have
time for that. (spent it all trying to figure out where my problem
was!)

Though, I might just switch to Firebird if I have to do some code
changing on my app anyway.  It's a bit more mature than Mysql's new
stuff. (considering it's still in beta)  Mysql is just so easy.

-



On 5/13/05, Greg Fischer [EMAIL PROTECTED] wrote:
 ok, lots of testing, and I have found that this is related to Mysql 5.0.4.
 
 I compiled and installed Mysql 5.0.0 and the problem does not exist. I
 guess means that it started in 5.0.1 or higher.  I read through the
 change logs and saw a couple of items related to float values on 5.0.3
 and 5.0.4, but I dont have any idea if those are causing the issue.
 
 So, I dont know where to go next.  I can post this info on the mysql
 lists, but I only see the problem in Zope.  Python, or at least the
 MysqlDA, retrieves the value just fine.  I only get the problem if
 using a fmt option on Zope.
 Here's a recap:
 -- I can use Zope 2.7.4 with Mysql 5.0.4 on Windows (using Egenix ODBC
 DA) and there is no issue.
 -- I can use Zope 2.7.3 with Mysql 5.0.0 on Linux (Zmysqlda 2.0.9b3,
 Mysql-python1.2.0,Python 2.3.4) and there is no issue.
 -- When using Zope 2.7.3 with same setup as before, but with Mysql
 5.0.4, problem exists.
 -- Zope 2.7.6 has same issue.
 
 I tried doing a simple dtml:
 dtml-call REQUEST.set('dec',10.23)
 dtml-var decbr
 dtml-var dec fmt=dollars-and-centsbr
 
 This works just fine.  But when pulling 'dec' from Mysql, dtml wont
 render it if using fmt.
 
 I dont have to use Mysql 5.x.  It's just that I already have the app
 running on it, and I'd like to start testing the stored procedures and
 other useful features.
 
 Sorry for the long post.  I just want to give as much info as
 possible.  Thank you for any help!
 
 Greg
 
 
 On 5/12/05, Greg Fischer [EMAIL PROTECTED] wrote:
  Oh, it is a decimal(15,2) column.  (all of them are)  Just thought I'd
  mention everything too... Running Ubuntu 5.0.4, has the Python 2.4.1
  package installed, but I have Python 2.3.4 compiled and installed
  separately for Zope.  Zope is compiled with the --with-python flag.
 
  Just tried your suggestion, commenting the 'conv[FIELD_TYPE.DECIMAL] =
  float' line, restart Zope, still have the issue.
 
  So, I have the older Python, which I used to have.  I could try
  loading an older Zope, but what I might try is loading the MySQL
  5.0.0, which I had before.  At least I can hopefully find out which is
  causing my problem.  However, I have Zope 2.7.4 with MySQL 5.0.4 and
  it works fine, but on Windows using the Egenix adapter.  Now, I cant
  remember what I had for the mysql-python version, it's on the other
  server at my clients site. (cant get to it right now)
 
  I guess one of my main questions too is, would Zope be getting
  anything from the 2.4.1 Ubuntu packages that are installed if I
  compiled it with the 2.3.4 python?  (mysql-python is installed
  correctly on 2.3.4 too)
 
  On 5/12/05, Andy Dustman [EMAIL PROTECTED] wrote:
   On 5/12/05, Greg Fischer [EMAIL PROTECTED] wrote:
Thanks Andy.  I do have those versions.  But Python is 2.3.5 because I
didnt want to move to 2.4.x as I think I read something in the README
for Zope stating it was not tested for compatibility. (right?)  I
guess my thought is... Does 2.3.5 have the same issue as 2.4 regarding
the decimals?  For now, I am just going to setup 2.3.4 and run with
it.
  
   The Python decimal type is new in 2.4.
  
   I don't think you've actually said whether or not you are actually
   using a DECIMAL column.
  
   I had forgotten that ZMySQLDA-2.0.9b3 always returns DECIMAL columns
   as Python float. If you look in ZMySQLDA/db.py, you can see where it
   does this in the DB class. You could try commenting this line out,
   which will cause it to be returned as a string, and restarting Zope.
   It's something to try, at least.
   --
   Computer interfaces should never be made of meat.
   http://www.terrybisson.com/meat.html
   ___
   Zope maillist  -  Zope@zope.org
   http://mail.zope.org/mailman/listinfo/zope
   **   No cross posts or HTML encoding!  **
   (Related lists -
http://mail.zope.org/mailman/listinfo/zope-announce
http://mail.zope.org/mailman/listinfo/zope-dev )
  
 
  --
  Greg Fischer
  1st Byte Solutions
  http://www.1stbyte.com
 
 
 --
 Greg Fischer
 1st Byte Solutions
 http://www.1stbyte.com
 


-- 
Greg Fischer
1st Byte Solutions
http://www.1stbyte.com

Re: [Zope] dollars-and-cents display fails

2005-05-14 Thread Greg Fischer
OK well, I fixed it. At least on My zope server.

The function for dollars-and-cents in DT_Var.py was like this:
def dollars_and_cents(v, name='(Unknown name)', md={}):
   try: return $%.2f % v
   except: return ''

I changed it to this:
def dollars_and_cents(v, name='(Unknown name)', md={}):
   try: return $%.2f % float(v)
   except: return ''

Problem solved.  I just tested it in Mysql 5.0.0 and 5.0.4, and it
works great.  I'll setup the rest of my app and test some more to make
sure I am not missing something. If there are any problems I'll post
more details.

Is this something that could be posted on the Zope Collector?  It
should probably be tested on lots of other Db's I bet.  But, one
question I have, should this be handled in the Mysql DA?

On 5/13/05, Greg Fischer [EMAIL PROTECTED] wrote:
 http://dev.mysql.com/doc/mysql/en/numeric-type-overview.html
 That's it right there!  Before 5.0.3, they were unpacked, meaning
 saved like a char.  Now they are packed, fixed point numbers.  This is
 screwing up the python functions for fmt.
 
 Well, I was trying to NOT redo all that code, but looks like I will
 have to if I want to run the new mysql.  I have tons of reports using
 dtml and fmt.   I think I'll stick with 5.0.0 for now until I have
 time for that. (spent it all trying to figure out where my problem
 was!)
 
 Though, I might just switch to Firebird if I have to do some code
 changing on my app anyway.  It's a bit more mature than Mysql's new
 stuff. (considering it's still in beta)  Mysql is just so easy.
 
 -
 
 
 On 5/13/05, Greg Fischer [EMAIL PROTECTED] wrote:
  ok, lots of testing, and I have found that this is related to Mysql 5.0.4.
 
  I compiled and installed Mysql 5.0.0 and the problem does not exist. I
  guess means that it started in 5.0.1 or higher.  I read through the
  change logs and saw a couple of items related to float values on 5.0.3
  and 5.0.4, but I dont have any idea if those are causing the issue.
 
  So, I dont know where to go next.  I can post this info on the mysql
  lists, but I only see the problem in Zope.  Python, or at least the
  MysqlDA, retrieves the value just fine.  I only get the problem if
  using a fmt option on Zope.
  Here's a recap:
  -- I can use Zope 2.7.4 with Mysql 5.0.4 on Windows (using Egenix ODBC
  DA) and there is no issue.
  -- I can use Zope 2.7.3 with Mysql 5.0.0 on Linux (Zmysqlda 2.0.9b3,
  Mysql-python1.2.0,Python 2.3.4) and there is no issue.
  -- When using Zope 2.7.3 with same setup as before, but with Mysql
  5.0.4, problem exists.
  -- Zope 2.7.6 has same issue.
 
  I tried doing a simple dtml:
  dtml-call REQUEST.set('dec',10.23)
  dtml-var decbr
  dtml-var dec fmt=dollars-and-centsbr
 
  This works just fine.  But when pulling 'dec' from Mysql, dtml wont
  render it if using fmt.
 
  I dont have to use Mysql 5.x.  It's just that I already have the app
  running on it, and I'd like to start testing the stored procedures and
  other useful features.
 
  Sorry for the long post.  I just want to give as much info as
  possible.  Thank you for any help!
 
  Greg
 
 
  On 5/12/05, Greg Fischer [EMAIL PROTECTED] wrote:
   Oh, it is a decimal(15,2) column.  (all of them are)  Just thought I'd
   mention everything too... Running Ubuntu 5.0.4, has the Python 2.4.1
   package installed, but I have Python 2.3.4 compiled and installed
   separately for Zope.  Zope is compiled with the --with-python flag.
  
   Just tried your suggestion, commenting the 'conv[FIELD_TYPE.DECIMAL] =
   float' line, restart Zope, still have the issue.
  
   So, I have the older Python, which I used to have.  I could try
   loading an older Zope, but what I might try is loading the MySQL
   5.0.0, which I had before.  At least I can hopefully find out which is
   causing my problem.  However, I have Zope 2.7.4 with MySQL 5.0.4 and
   it works fine, but on Windows using the Egenix adapter.  Now, I cant
   remember what I had for the mysql-python version, it's on the other
   server at my clients site. (cant get to it right now)
  
   I guess one of my main questions too is, would Zope be getting
   anything from the 2.4.1 Ubuntu packages that are installed if I
   compiled it with the 2.3.4 python?  (mysql-python is installed
   correctly on 2.3.4 too)
  
   On 5/12/05, Andy Dustman [EMAIL PROTECTED] wrote:
On 5/12/05, Greg Fischer [EMAIL PROTECTED] wrote:
 Thanks Andy.  I do have those versions.  But Python is 2.3.5 because I
 didnt want to move to 2.4.x as I think I read something in the README
 for Zope stating it was not tested for compatibility. (right?)  I
 guess my thought is... Does 2.3.5 have the same issue as 2.4 regarding
 the decimals?  For now, I am just going to setup 2.3.4 and run with
 it.
   
The Python decimal type is new in 2.4.
   
I don't think you've actually said whether or not you are actually
using a DECIMAL column.
   
I had forgotten that ZMySQLDA-2.0.9b3 always returns DECIMAL columns

Re: [Zope] dollars-and-cents display fails

2005-05-14 Thread Greg Fischer
I guess my quick fix wont work.  Well, it fixes the fmt for decimals,
but there's more to the issue.  Statistical summaries, total, sum dont
work either.
In my dtml-in I might have this:
dtml-var total-decimalcolumn
or
dtml-var sum-decimalcolumn

These dont work with Mysql 5.0.4.  So, what do we have to change in
the Mysql DA or maybe the Mysql-python to fix this?

If I find anything, I'll post more.

On 5/13/05, Greg Fischer [EMAIL PROTECTED] wrote:
 OK well, I fixed it. At least on My zope server.
 
 The function for dollars-and-cents in DT_Var.py was like this:
 def dollars_and_cents(v, name='(Unknown name)', md={}):
try: return $%.2f % v
except: return ''
 
 I changed it to this:
 def dollars_and_cents(v, name='(Unknown name)', md={}):
try: return $%.2f % float(v)
except: return ''
 
 Problem solved.  I just tested it in Mysql 5.0.0 and 5.0.4, and it
 works great.  I'll setup the rest of my app and test some more to make
 sure I am not missing something. If there are any problems I'll post
 more details.
 
 Is this something that could be posted on the Zope Collector?  It
 should probably be tested on lots of other Db's I bet.  But, one
 question I have, should this be handled in the Mysql DA?
 
 On 5/13/05, Greg Fischer [EMAIL PROTECTED] wrote:
  http://dev.mysql.com/doc/mysql/en/numeric-type-overview.html
  That's it right there!  Before 5.0.3, they were unpacked, meaning
  saved like a char.  Now they are packed, fixed point numbers.  This is
  screwing up the python functions for fmt.
 
  Well, I was trying to NOT redo all that code, but looks like I will
  have to if I want to run the new mysql.  I have tons of reports using
  dtml and fmt.   I think I'll stick with 5.0.0 for now until I have
  time for that. (spent it all trying to figure out where my problem
  was!)
 
  Though, I might just switch to Firebird if I have to do some code
  changing on my app anyway.  It's a bit more mature than Mysql's new
  stuff. (considering it's still in beta)  Mysql is just so easy.
 
  -
 
 
  On 5/13/05, Greg Fischer [EMAIL PROTECTED] wrote:
   ok, lots of testing, and I have found that this is related to Mysql 5.0.4.
  
   I compiled and installed Mysql 5.0.0 and the problem does not exist. I
   guess means that it started in 5.0.1 or higher.  I read through the
   change logs and saw a couple of items related to float values on 5.0.3
   and 5.0.4, but I dont have any idea if those are causing the issue.
  
   So, I dont know where to go next.  I can post this info on the mysql
   lists, but I only see the problem in Zope.  Python, or at least the
   MysqlDA, retrieves the value just fine.  I only get the problem if
   using a fmt option on Zope.
   Here's a recap:
   -- I can use Zope 2.7.4 with Mysql 5.0.4 on Windows (using Egenix ODBC
   DA) and there is no issue.
   -- I can use Zope 2.7.3 with Mysql 5.0.0 on Linux (Zmysqlda 2.0.9b3,
   Mysql-python1.2.0,Python 2.3.4) and there is no issue.
   -- When using Zope 2.7.3 with same setup as before, but with Mysql
   5.0.4, problem exists.
   -- Zope 2.7.6 has same issue.
  
   I tried doing a simple dtml:
   dtml-call REQUEST.set('dec',10.23)
   dtml-var decbr
   dtml-var dec fmt=dollars-and-centsbr
  
   This works just fine.  But when pulling 'dec' from Mysql, dtml wont
   render it if using fmt.
  
   I dont have to use Mysql 5.x.  It's just that I already have the app
   running on it, and I'd like to start testing the stored procedures and
   other useful features.
  
   Sorry for the long post.  I just want to give as much info as
   possible.  Thank you for any help!
  
   Greg
  
  
   On 5/12/05, Greg Fischer [EMAIL PROTECTED] wrote:
Oh, it is a decimal(15,2) column.  (all of them are)  Just thought I'd
mention everything too... Running Ubuntu 5.0.4, has the Python 2.4.1
package installed, but I have Python 2.3.4 compiled and installed
separately for Zope.  Zope is compiled with the --with-python flag.
   
Just tried your suggestion, commenting the 'conv[FIELD_TYPE.DECIMAL] =
float' line, restart Zope, still have the issue.
   
So, I have the older Python, which I used to have.  I could try
loading an older Zope, but what I might try is loading the MySQL
5.0.0, which I had before.  At least I can hopefully find out which is
causing my problem.  However, I have Zope 2.7.4 with MySQL 5.0.4 and
it works fine, but on Windows using the Egenix adapter.  Now, I cant
remember what I had for the mysql-python version, it's on the other
server at my clients site. (cant get to it right now)
   
I guess one of my main questions too is, would Zope be getting
anything from the 2.4.1 Ubuntu packages that are installed if I
compiled it with the 2.3.4 python?  (mysql-python is installed
correctly on 2.3.4 too)
   
On 5/12/05, Andy Dustman [EMAIL PROTECTED] wrote:
 On 5/12/05, Greg Fischer [EMAIL PROTECTED] wrote:
  Thanks Andy.  I do have those versions

Re: [Zope] dollars-and-cents display fails

2005-05-13 Thread Greg Fischer
ok, lots of testing, and I have found that this is related to Mysql 5.0.4.

I compiled and installed Mysql 5.0.0 and the problem does not exist. I
guess means that it started in 5.0.1 or higher.  I read through the
change logs and saw a couple of items related to float values on 5.0.3
and 5.0.4, but I dont have any idea if those are causing the issue.

So, I dont know where to go next.  I can post this info on the mysql
lists, but I only see the problem in Zope.  Python, or at least the
MysqlDA, retrieves the value just fine.  I only get the problem if
using a fmt option on Zope.
Here's a recap: 
-- I can use Zope 2.7.4 with Mysql 5.0.4 on Windows (using Egenix ODBC
DA) and there is no issue.
-- I can use Zope 2.7.3 with Mysql 5.0.0 on Linux (Zmysqlda 2.0.9b3,
Mysql-python1.2.0,Python 2.3.4) and there is no issue.
-- When using Zope 2.7.3 with same setup as before, but with Mysql
5.0.4, problem exists.
-- Zope 2.7.6 has same issue.

I tried doing a simple dtml:
dtml-call REQUEST.set('dec',10.23)
dtml-var decbr
dtml-var dec fmt=dollars-and-centsbr

This works just fine.  But when pulling 'dec' from Mysql, dtml wont
render it if using fmt.

I dont have to use Mysql 5.x.  It's just that I already have the app
running on it, and I'd like to start testing the stored procedures and
other useful features.

Sorry for the long post.  I just want to give as much info as
possible.  Thank you for any help!

Greg



On 5/12/05, Greg Fischer [EMAIL PROTECTED] wrote:
 Oh, it is a decimal(15,2) column.  (all of them are)  Just thought I'd
 mention everything too... Running Ubuntu 5.0.4, has the Python 2.4.1
 package installed, but I have Python 2.3.4 compiled and installed
 separately for Zope.  Zope is compiled with the --with-python flag.
 
 Just tried your suggestion, commenting the 'conv[FIELD_TYPE.DECIMAL] =
 float' line, restart Zope, still have the issue.
 
 So, I have the older Python, which I used to have.  I could try
 loading an older Zope, but what I might try is loading the MySQL
 5.0.0, which I had before.  At least I can hopefully find out which is
 causing my problem.  However, I have Zope 2.7.4 with MySQL 5.0.4 and
 it works fine, but on Windows using the Egenix adapter.  Now, I cant
 remember what I had for the mysql-python version, it's on the other
 server at my clients site. (cant get to it right now)
 
 I guess one of my main questions too is, would Zope be getting
 anything from the 2.4.1 Ubuntu packages that are installed if I
 compiled it with the 2.3.4 python?  (mysql-python is installed
 correctly on 2.3.4 too)
 
 On 5/12/05, Andy Dustman [EMAIL PROTECTED] wrote:
  On 5/12/05, Greg Fischer [EMAIL PROTECTED] wrote:
   Thanks Andy.  I do have those versions.  But Python is 2.3.5 because I
   didnt want to move to 2.4.x as I think I read something in the README
   for Zope stating it was not tested for compatibility. (right?)  I
   guess my thought is... Does 2.3.5 have the same issue as 2.4 regarding
   the decimals?  For now, I am just going to setup 2.3.4 and run with
   it.
 
  The Python decimal type is new in 2.4.
 
  I don't think you've actually said whether or not you are actually
  using a DECIMAL column.
 
  I had forgotten that ZMySQLDA-2.0.9b3 always returns DECIMAL columns
  as Python float. If you look in ZMySQLDA/db.py, you can see where it
  does this in the DB class. You could try commenting this line out,
  which will cause it to be returned as a string, and restarting Zope.
  It's something to try, at least.
  --
  Computer interfaces should never be made of meat.
  http://www.terrybisson.com/meat.html
  ___
  Zope maillist  -  Zope@zope.org
  http://mail.zope.org/mailman/listinfo/zope
  **   No cross posts or HTML encoding!  **
  (Related lists -
   http://mail.zope.org/mailman/listinfo/zope-announce
   http://mail.zope.org/mailman/listinfo/zope-dev )
 
 
 --
 Greg Fischer
 1st Byte Solutions
 http://www.1stbyte.com
 


-- 
Greg Fischer
1st Byte Solutions
http://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


[Zope] dollars-and-cents display fails

2005-05-12 Thread Greg Fischer
Hi all,

I just moved my zope app from 2.7.3 to 2.7.6, plus the mysql db from
5.0.0 to 5.0.4.  After moving everything, I noticed all of my decimal
fields that will no longer display their values in DTML unless I
remove the dollars-and-cents fmt option.

I tried all kinds of things in mysql thinking that was it because I
knew there have been some major changes in that, but I couldnt find
anything there.  I tested a query from the mysql connection test, and
it retrieves the values fine.

Then I noticed, if I remove the fmt=dollars-and-cents, it would
work. Any thoughts on why this is?  Is it a security option on the
folder or other items?

I could just remove all the formatting, but I'd rather not.  Thanks
for any help!
-- 
Greg Fischer
1st Byte Solutions
http://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] dollars-and-cents display fails

2005-05-12 Thread Greg Fischer
Thanks Andy.  I do have those versions.  But Python is 2.3.5 because I
didnt want to move to 2.4.x as I think I read something in the README
for Zope stating it was not tested for compatibility. (right?)  I
guess my thought is... Does 2.3.5 have the same issue as 2.4 regarding
the decimals?  For now, I am just going to setup 2.3.4 and run with
it.

I am assuming that you are the same adustman on the mysql-python
project?  Nice job on that, very cool stuff!


On 5/12/05, Andy Dustman [EMAIL PROTECTED] wrote:
 On 5/12/05, Greg Fischer [EMAIL PROTECTED] wrote:
  I just moved my zope app from 2.7.3 to 2.7.6, plus the mysql db from
  5.0.0 to 5.0.4.  After moving everything, I noticed all of my decimal
  fields that will no longer display their values in DTML unless I
  remove the dollars-and-cents fmt option.
 
 What version of MySQL-python and ZMySQLDA are you using? For
 MySQL-5.0, you definitely need MySQL-python-1.2.0 or newer and
 ZMySQLDA-2.0.9b3. You aren't using Python-2.4 by any chance, are you?
 2.4 has a decimal type, which MySQL-python will make use of, if it's
 there, and the DECIMAL columns are returned using the Python decimal
 type. Previously they would have been returned as strings, and that
 might account for your breakage.
 
 --
 Computer interfaces should never be made of meat.
 http://www.terrybisson.com/meat.html
 ___
 Zope maillist  -  Zope@zope.org
 http://mail.zope.org/mailman/listinfo/zope
 **   No cross posts or HTML encoding!  **
 (Related lists -
  http://mail.zope.org/mailman/listinfo/zope-announce
  http://mail.zope.org/mailman/listinfo/zope-dev )
 


-- 
Greg Fischer
1st Byte Solutions
http://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] dollars-and-cents display fails

2005-05-12 Thread Greg Fischer
Darn!  That didnt fix it.  I just setup python 2.3.4, setup Zope 2.7.6
again, along with mysql-python 1.2.0 and ZMySQLDA-2.0.9b3, and
fmt=dollars-and-cents will not display the data.  Also, I tried just
using the c-style formatting: fmt=$%.2f and I have a different
issue, I get a Type Error - float argument required.  So how do I fix
this decimal or string issue?  Is there something on MySQL needing
setup differently? (which is 5.0.4beta)  Seems more like Python or
Zope issue.

Any ideas to get me in the right direction?

Thanks!


On 5/12/05, Andy Dustman [EMAIL PROTECTED] wrote:
 On 5/12/05, Greg Fischer [EMAIL PROTECTED] wrote:
  I just moved my zope app from 2.7.3 to 2.7.6, plus the mysql db from
  5.0.0 to 5.0.4.  After moving everything, I noticed all of my decimal
  fields that will no longer display their values in DTML unless I
  remove the dollars-and-cents fmt option.
 
 What version of MySQL-python and ZMySQLDA are you using? For
 MySQL-5.0, you definitely need MySQL-python-1.2.0 or newer and
 ZMySQLDA-2.0.9b3. You aren't using Python-2.4 by any chance, are you?
 2.4 has a decimal type, which MySQL-python will make use of, if it's
 there, and the DECIMAL columns are returned using the Python decimal
 type. Previously they would have been returned as strings, and that
 might account for your breakage.
 
 --
 Computer interfaces should never be made of meat.
 http://www.terrybisson.com/meat.html
 ___
 Zope maillist  -  Zope@zope.org
 http://mail.zope.org/mailman/listinfo/zope
 **   No cross posts or HTML encoding!  **
 (Related lists -
  http://mail.zope.org/mailman/listinfo/zope-announce
  http://mail.zope.org/mailman/listinfo/zope-dev )
 


-- 
Greg Fischer
1st Byte Solutions
http://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )


Re: [Zope] dollars-and-cents display fails

2005-05-12 Thread Greg Fischer
Oh, it is a decimal(15,2) column.  (all of them are)  Just thought I'd
mention everything too... Running Ubuntu 5.0.4, has the Python 2.4.1
package installed, but I have Python 2.3.4 compiled and installed
separately for Zope.  Zope is compiled with the --with-python flag.

Just tried your suggestion, commenting the 'conv[FIELD_TYPE.DECIMAL] =
float' line, restart Zope, still have the issue.

So, I have the older Python, which I used to have.  I could try
loading an older Zope, but what I might try is loading the MySQL
5.0.0, which I had before.  At least I can hopefully find out which is
causing my problem.  However, I have Zope 2.7.4 with MySQL 5.0.4 and
it works fine, but on Windows using the Egenix adapter.  Now, I cant
remember what I had for the mysql-python version, it's on the other
server at my clients site. (cant get to it right now)

I guess one of my main questions too is, would Zope be getting
anything from the 2.4.1 Ubuntu packages that are installed if I
compiled it with the 2.3.4 python?  (mysql-python is installed
correctly on 2.3.4 too)

On 5/12/05, Andy Dustman [EMAIL PROTECTED] wrote:
 On 5/12/05, Greg Fischer [EMAIL PROTECTED] wrote:
  Thanks Andy.  I do have those versions.  But Python is 2.3.5 because I
  didnt want to move to 2.4.x as I think I read something in the README
  for Zope stating it was not tested for compatibility. (right?)  I
  guess my thought is... Does 2.3.5 have the same issue as 2.4 regarding
  the decimals?  For now, I am just going to setup 2.3.4 and run with
  it.
 
 The Python decimal type is new in 2.4.
 
 I don't think you've actually said whether or not you are actually
 using a DECIMAL column.
 
 I had forgotten that ZMySQLDA-2.0.9b3 always returns DECIMAL columns
 as Python float. If you look in ZMySQLDA/db.py, you can see where it
 does this in the DB class. You could try commenting this line out,
 which will cause it to be returned as a string, and restarting Zope.
 It's something to try, at least.
 --
 Computer interfaces should never be made of meat.
 http://www.terrybisson.com/meat.html
 ___
 Zope maillist  -  Zope@zope.org
 http://mail.zope.org/mailman/listinfo/zope
 **   No cross posts or HTML encoding!  **
 (Related lists -
  http://mail.zope.org/mailman/listinfo/zope-announce
  http://mail.zope.org/mailman/listinfo/zope-dev )
 


-- 
Greg Fischer
1st Byte Solutions
http://www.1stbyte.com
___
Zope maillist  -  Zope@zope.org
http://mail.zope.org/mailman/listinfo/zope
**   No cross posts or HTML encoding!  **
(Related lists -
 http://mail.zope.org/mailman/listinfo/zope-announce
 http://mail.zope.org/mailman/listinfo/zope-dev )