[Zope] python prob

Vangelis Mihalopoulos mihalop at VTrip.NET
Tue Mar 29 08:25:41 EST 2005


Also, i don't think that ZSQL methods return a simple string, so the 
comparison is between wrong types of objects....

Pascal Peregrina wrote:

>Also, I think that :
>
>"else"
>
>should be :
>
>"else:"
>
>Pascal
>
>-----Message d'origine-----
>De : zope-bounces at zope.org [mailto:zope-bounces at zope.org]De la part de
>Vangelis Mihalopoulos
>Envoyé : mardi 29 mars 2005 14:03
>À : prabuddha ray
>Cc : zpugdc at zope.org; zope at zope.org
>Objet : Re: [Zope] python prob
>
>
>Indentation maybe?
>the if-else part should be on the outer indent like......
>
>req = container.REQUEST
>RESP =  request.RESPONSE
>
>user=req.username
>pwd=req.password
># chkpwd is a ZSQL method taking username as arg and giving its
>correspong passwd
>if  container.chkpwd(user)==pwd :            #    it givs syntax error here
>	RESP.redirect(test)
>else
>	RESP.redirect(index_html)
>
>
>
>prabuddha ray wrote:
>
>  
>
>>i'm kinda new to python ;
>>wanted to build an intermediate scrip python for redirection from a ZPT .
>>code tried is 
>>
>>req = container.REQUEST
>>RESP =  request.RESPONSE
>>
>>user=req.username
>>pwd=req.password
>># chkpwd is a ZSQL method taking username as arg and giving its
>>correspong passwd
>>	if  container.chkpwd(user)==pwd :            #    it givs syntax
>>    
>>
>error here
>  
>
>>		RESP.redirect(test)
>>	else
>>		RESP.redirect(index_html)
>>
>>plz help
>> 
>>
>>    
>>
>_______________________________________________
>Zope maillist  -  Zope at 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 )
>
>
>**********************************************************************
>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 at 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 )
>  
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.zope.org/pipermail/zope/attachments/20050329/353959f4/attachment.htm


More information about the Zope mailing list