[Zope] PyCon UK Approaching...

2008-07-16 Thread Chris Withers

Hi All,

Apologies for what might be seen as spam but I wasn't even aware this 
conference took place last year and I live in the UK! So, hopefully you 
won't mind me letting you know that it's taking place again this year ;-)


PyCon UK 2008 is an independent, community-run, community-controlled
and not-for-profit conference dedicated to the Python programming
language, Python applications, toolkits and frameworks. It also
features social events and a chance to meet fellow Python users. It is
organised by members of Python User Groups from across the United
Kingdom.

PyCon UK 2008 will be taking place in Birmingham City Centre from the
12th-14th September. It will feature the leading members of the UK
Python community as well as Ted Leung from Sun Microsystems, Jacob
Kaplan-Moss from the Django Project and Mark Shuttleworth, a developer
of the Bazaar Version Control System and founder of the Ubuntu Linux
distribution.

PyConUK will feature around 60 talks and tutorials, a conference
dinner and two pub events. Booking is open now at
http://pyconuk.org/booking.html   Further Information is available at
http://pyconuk.org/

Hope to see you there!

Chris :-)

--
Simplistix - Content Management, Zope & Python Consulting
   - http://www.simplistix.co.uk
___
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] TALES expression

2008-07-16 Thread Garito
Hi!
Please consider this TALES expression:



If I try this other:  the
result is None

Then the first one will render the alternate expression isn't it?

Then with it renders  ?

Thanks!

-- 
Mis Cosas
http://blogs.sistes.net/Garito
Zope Smart Manager
http://blogs.sistes.net/Garito/670
___
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] TALES expression

2008-07-16 Thread Martijn Jacobs



Hi!
Please consider this TALES expression:




If I try this other:  
the result is None


Then the first one will render the alternate expression isn't it?

Then with it renders  ?

Thanks!


I don't understand what you are asking. Could you describe your question 
more clear please.



Martijn.

--
Martijn Jacobs
Four Digits, Internet Solutions

a: Willemsplein 15-1 6811 KB Arnhem NL 
kvk: 09162137 | btw: 8161.22.234.B01

e-mail: [EMAIL PROTECTED] | web: http://www.fourdigits.nl
tel: +31 (0)26 44 22 700 | fax: +31 (0)84 22 06 117 


___
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] Redirect URL

2008-07-16 Thread Subhendu Kumar Giri




I modify the rewrite rule



ServerName mydomain.org
RewriteEngine On
RewriteRule ^/article/view/([0-9]*)/(.*) /archieve/$1 [R]
RewriteRule ^/zoperoot(.*)
http://xxx.xxx.xxx.xxx:8080/VirtualHostBase/http/mydomain.org:80/VirtualHostRoot/_vh_zoperoot$1
[P,L]
RewriteRule  ^/(.*) 
http://xxx.xxx.xxx.xxx:8080/VirtualHostBase/http/mydomain.org:80/mydomaininstance/VirtualHostRoot/$1 
[P,L]


and it is working 
Thanks for the support.

Subhendu


Subhendu Kumar Giri wrote:

  
Andreas,
  
Thanks for the response.
  
I write in rewrite rule in httpd.conf
  

ServerName mydomain.org
ServerAlias www.mydomain.org
ProxyPass /
  http://xxx.xxx.xxx.xxx/VirtualHostBase/http/mydomain.org:80/mydomaininstance/VirtualHostRoot/
ProxyPassReverse /
  http://xxx.xxx.xxx.xxx:8080/VirtualHostBase/http/mydomain.org:80/mydomaininstance/VirtualHostRoot/

  
How can i redirect www.mydomain.com/article/view/11525/1/
to
  www.mydomain.com/archieve/11525
  
  
Andreas Jung wrote:
  

--On 15. Juli 2008 13:14:53 +0530 Subhendu Kumar Giri
<[EMAIL PROTECTED]>
wrote: 

Hi All, 
  
Previously I have a website running in php. Now we migrated it to plone
  
2.5.5 and zope 2.9. After that I want to maintain all the previous
links 
. Earlier it was like  www.mydomain.com/article/view/11525/1/
(where 
11525 is the article id). Now I created a archieve folder where I 
migrated the contents. The new link is www.mydomain.com/archieve/11525.
I 
tried to redirect it from default_error_message but it did not work as
it 
shows the folder contents of article folder. 
  
What should be done to redirect the old url to new url. 


Apache rewrite rules? 

-aj
  


-- 


Subhendu Kumar Giri
Subhendu Kumar Giri [शुभेन्दु कुमार गिरि]






___
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] TALES expression

2008-07-16 Thread Garito
If this assuption is correct why the result is ?

2008/7/16 Martijn Jacobs <[EMAIL PROTECTED]>:

>  That assumption is correct
>
>  I mean some TALES expression as here/getDataInici | string: nosta will
> evaluate here/getDataInici and if this expression returns '', 0 or None the
> tal interpreter evaluates the second one and the result of this TALES
> expression will be nosta as string
>
> Is this assumption correct?
>
> Thanks!
>
> 2008/7/16 Martijn Jacobs <[EMAIL PROTECTED]>:
>
>>
>>  Hi!
>>> Please consider this TALES expression:
>>>
>>> >> />
>>>
>>> If I try this other: 
>>> the result is None
>>>
>>> Then the first one will render the alternate expression isn't it?
>>>
>>> Then with it renders  ?
>>>
>>> Thanks!
>>>
>>
>>  I don't understand what you are asking. Could you describe your question
>> more clear please.
>>
>>
>> Martijn.
>>
>> --
>> Martijn Jacobs
>> Four Digits, Internet Solutions
>>
>> a: Willemsplein 15-1 6811 KB Arnhem NL kvk: 09162137 | btw:
>> 8161.22.234.B01
>> e-mail: [EMAIL PROTECTED] | web: http://www.fourdigits.nl
>> tel: +31 (0)26 44 22 700 | fax: +31 (0)84 22 06 117
>>
>
>
>
> --
> Mis Cosas
> http://blogs.sistes.net/Garito
> Zope Smart Manager
> http://blogs.sistes.net/Garito/670
>
>
>
> --
> Martijn Jacobs
> Four Digits, Internet Solutions
>
> a: Willemsplein 15-1 6811 KB Arnhem NL
> kvk: 09162137 | btw: 8161.22.234.B01
> e-mail: [EMAIL PROTECTED] | web: http://www.fourdigits.nl
> tel: +31 (0)26 44 22 700 | fax: +31 (0)84 22 06 117
>
>


-- 
Mis Cosas
http://blogs.sistes.net/Garito
Zope Smart Manager
http://blogs.sistes.net/Garito/670
___
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 reconnects on zope application level

2008-07-16 Thread Jonas
Hello,

On several zope 2.10.6 instances we discovered issues with database
connections to MySQL. Apparently MySQL seems to not automaticly
reconnect connections with a timeout since version 5.0.3 due to issues
with transactions.

Until now, mysql-python was patched to restore that behaviour to
automatically reconnect timeouted connections, but that is not the case
anymore either.

So from now on the database reconnects need to be done from zope
applications on their own. Unfortunately the ZMySQLda adapter by Andy
Dustman doesn't implement such a functionality.

I cannot imagine that we are the only ones who discover this problem. Is
there an easy way to implement automatic reconnects for Z MySQL Database
Connections on zope application level?

greetings, and thanks in advance,
 jonas
___
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] TALES expression

2008-07-16 Thread Tino Wildenhain

Garito wrote:

Hi!
Please consider this TALES expression:



If I try this other:  
the result is None


Then the first one will render the alternate expression isn't it?

Then with it renders  ?


Сто? ;-)

You should check the tales documentation. the pipe symbol |
means a logical "or", in effect if the left expression resolves
to "non existent", None, empty object,... (generally python False)
the right part of it is evaluated.

In the special case it probably is nicer to use:

nosta instead so the fallback value is part

of the template (TAL is meant to be design by example)

I would also recommend not mixing " and ' for attributes and
maybe in the long run sticking to english language names for
your objects makes it easier to ask on mailinglists.

Regards
Tino



smime.p7s
Description: S/MIME Cryptographic Signature
___
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] TALES expression

2008-07-16 Thread Fred Drake
On Wed, Jul 16, 2008 at 6:34 AM, Tino Wildenhain <[EMAIL PROTECTED]> wrote:
> You should check the tales documentation. the pipe symbol |
> means a logical "or", in effect if the left expression resolves
> to "non existent", None, empty object,... (generally python False)
> the right part of it is evaluated.

Not at all.

The pipe uses the left-hand operand if it is defined; a value of None
or an empty string is still a defined value.  As long as "here" can be
traversed with the name "getDataInici" then the left-hand expression
will be used.  If that traversal fails the right-hand expression will
be used instead.


 -Fred

-- 
Fred L. Drake, Jr. 
"Chaos is the score upon which reality is written." --Henry Miller
___
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 reconnects on zope application level

2008-07-16 Thread Peter Bengtsson
I don't have an easy answer but if you do dig into Andy's code and try
to implement this, I would suggest you look at the ZPsycopgDA code
perhaps and look for inspiration since I think that one works much
better.


2008/7/16 Jonas <[EMAIL PROTECTED]>:
> Hello,
>
> On several zope 2.10.6 instances we discovered issues with database
> connections to MySQL. Apparently MySQL seems to not automaticly
> reconnect connections with a timeout since version 5.0.3 due to issues
> with transactions.
>
> Until now, mysql-python was patched to restore that behaviour to
> automatically reconnect timeouted connections, but that is not the case
> anymore either.
>
> So from now on the database reconnects need to be done from zope
> applications on their own. Unfortunately the ZMySQLda adapter by Andy
> Dustman doesn't implement such a functionality.
>
> I cannot imagine that we are the only ones who discover this problem. Is
> there an easy way to implement automatic reconnects for Z MySQL Database
> Connections on zope application level?
>
> greetings, and thanks in advance,
>  jonas
> ___
> 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 )
>



-- 
Peter Bengtsson,
work www.fry-it.com
home www.peterbe.com
hobby www.issuetrackerproduct.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] TALES expression

2008-07-16 Thread Tino Wildenhain

Fred Drake wrote:

On Wed, Jul 16, 2008 at 6:34 AM, Tino Wildenhain <[EMAIL PROTECTED]> wrote:

You should check the tales documentation. the pipe symbol |
means a logical "or", in effect if the left expression resolves
to "non existent", None, empty object,... (generally python False)
the right part of it is evaluated.


Not at all.

The pipe uses the left-hand operand if it is defined; a value of None
or an empty string is still a defined value.  As long as "here" can be
traversed with the name "getDataInici" then the left-hand expression
will be used.  If that traversal fails the right-hand expression will
be used instead.


Indeed :-)

Cheers
Tino


smime.p7s
Description: S/MIME Cryptographic Signature
___
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] zexp import fails from linux to windows due to image file paths

2008-07-16 Thread Richard Ettema

Hi,

I have an old zope based site that was hosted on a linux machine that  
was exported to a zexp. i am trying to import it onto a windows  
machine to fix up and upgrade the site. the windows machine is setup  
wth the identical products etc. The problem is the image file paths  
for linux within the zexp do not match the new windows setup. I dont  
need the images imported, i'm wanting to access the main site content  
and users. I dont have access to a linux machine anymore, so i'm stuck  
with windows for development. Is there a way of getting the import  
procedure to ignore the errors and continue the import (i.e. any hints  
on how to modify the zope code)? Or is there a way to edit the zexp to  
do a search & remove/replace of the file path names so the import  
completes with no file path details?


Any ideas greatly appreciated as I have searched around with no luck on
answering this myself.

Thanks

___
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] zexp import fails from linux to windows due to image filepaths

2008-07-16 Thread Jaroslav Lukesh

From: "Richard Ettema" <[EMAIL PROTECTED]>
with windows for development. Is there a way of getting the import 
procedure to ignore the errors and continue the import (i.e. any hints  on 
how to modify the zope code)? Or is there a way to edit the zexp to  do a 
search & remove/replace of the file path names so the import  completes 
with no file path details?


You need to export your website folder as ZEXP in XML format. Then you could 
edit this file at search/replace basis. But before this, try to re-import 
this ZEXP file, if it is able to import (not all zexp exports are able to 
reimport).


Regards, JL. 


___
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] zexp import fails from linux to windows due to image filepaths

2008-07-16 Thread Richard Ettema

Quoting Jaroslav Lukesh <[EMAIL PROTECTED]>:



You need to export your website folder as ZEXP in XML format. Then you
could edit this file at search/replace basis. But before this, try to
re-import this ZEXP file, if it is able to import (not all zexp exports
are able to reimport).

Regards, JL.


Thanks for the reply JL, re-importing into the original server and  
exporting in XML is not an option as I don't have the server anymore,  
only a Windows machine.
If editing the existing ZEXP is not possible, is it possible to modify  
the actual zope code temporarily, to ignore the mismatch of file paths  
(or to modify the paths from linux to windows during the import  
process)?

Thanks, Rich

___
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] zexp import fails from linux to windows due to image file paths

2008-07-16 Thread robert rottermann

Richard Ettema schrieb:

Hi,

I have an old zope based site that was hosted on a linux machine that 
was exported to a zexp. i am trying to import it onto a windows machine 
to fix up and upgrade the site. the windows machine is setup wth the 
identical products etc. The problem is the image file paths for linux 
within the zexp do not match the new windows setup. I dont need the 
images imported, i'm wanting to access the main site content and users. 
I dont have access to a linux machine anymore, so i'm stuck with windows 
for development. Is there a way of getting the import procedure to 
ignore the errors and continue the import (i.e. any hints on how to 
modify the zope code)? Or is there a way to edit the zexp to do a search 
& remove/replace of the file path names so the import completes with no 
file path details?


Any ideas greatly appreciated as I have searched around with no luck on
answering this myself.

i do not think that it is the zexp import machinery that fails but the product 
that handles these external images. so you have to fix that product that it does 
not chocke when it can not read a file.


robert
___
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 )