Re: [Zope] Calling a Variable

2007-03-08 Thread eXt
Dnia czwartek, 8 marca 2007 18:48, [EMAIL PROTECTED] napisał:
 Hi;
 I thought I could call a variable in a page template by defining it and then 
putting a ? in front of it in a URL, like this:
You messed some things. First go to google.com and look into address bar in 
your browser. Then enter any value into search box (plz don't ask me what 
is any value ;) ) and click search. Look into the address bar again. You 
will see there something like: 
google.com?variable_name=variable_valueanother_variable_name=another_variable_value
 
etc. google.com is in your case base_url, and things after ? and  are 
variables that are passed to server (in your case Zope) from your browser 
(via request).

 html tal:define=global base_url here/baseURL;
 template_id string:index;
 here python:here.restrictedTraverse('s/c/x/root/en-us/Help')
Do you really want to define a variable named here?

 a href=?base_url/contactus.pt
What you want here is: base_url/contactus.pt?variable=variable_value. To put a 
variable value into href attribute use tal:attributes=href ...

 Please tell me what I'm doing wrong.
I tried to be a bit more specific that guys in other answers but please do 
what they suggested to you: read zope book :)

 Tony

-- 
Jakub Wisniowski
___
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] Simple Question

2006-12-07 Thread eXt
Dnia piątek, 8 grudnia 2006 00:32, Nancy Donnelly napisał:
 Hmmm. I have a problem. The following code works perfectly with the system I 
have set up on about 400 pages...something I clearly wouldn't want to 
re-edit...*except* for the 2nd line, which calls a script. Now, that second 
line *by itself* works just fine!! I've tested both the above scenarios. But 
in combination, it doesn't work. Why?

I've got a piece of code that works and at the same time doesn't work. This 
code calls a script that works but at the same time doesn't work. Of course I 
won't tell you what kind of error I get and I won't show you my traceback. 
Nancy, what is wrong with my code?

Are you able to help my? No? Sorry but no one will be able to help you if you 
keep defining your problems like that.


-- 
Jakub Wisniowski
___
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] Zope 2.9 vs Zope 2.10 and Unicode problems

2006-10-19 Thread eXt
On Thursday 19 October 2006 14:55, Doyon, Jean-Francois wrote:
 Any ideas?
http://www.zope.org/Collectors/Zope/2204 and... one more bug but I don't 
remember it's number. Please search zope3-five mailing list archives for zope 
2.10 and UnicodeDecodeErrors.


-- 
Jakub Wisniowski
___
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] Path expression in Python based script

2006-09-29 Thread eXt
Dnia piątek, 29 września 2006 09:00, Daniel de la Cuesta napisał:
 Hi, I am beginner working with Zope. I like it but I have some doubts:
 
 I have an structure with folders and subfoulders, each folder and subfolder 
has items.
 
 I want to go round this structre with a Python based script, to know the 
number of elements i do the following:
Subject of your post is confusing for me. Path expressions is a term from 
PageTemplates world. Look at path expressions:
span tal:content=request/parameter/span
or
span tal:content=python:path('options/parameter')/span

 path=animals
path is a local variable (for your 'Script (Python)')

 items=len(context.sections.path.contentValues())
Here you try to find an object (Folder) called 'path' inside object 
called 'sections'.
 
 When I try to run the script I get an error saying that the variable path 
is not present.
Yup, there is no 'path' object inside 'sections'.

 If i do:
 
 items=len(context.sections.animals.contentValues())
 everything is ok,
because there is 'animals' object

 How can I refer to a variable into a path expression in a Python Based 
Script?
Try: context.sections[path].contentValues()


-- 
eXt
___
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] copying folder?

2006-07-27 Thread eXt
Dnia czwartek, 27 lipca 2006 18:11, vl napisał:
 Andreas Jung wrote:
  Write a PythonScript that use the CopySupport API
  (manage_copyObjects/manage_pasteObjects) and call this script through
  your favorite URL fetcher
  (triggered through cron).
 
 Yes, that would work.  Thanks.  I should of thought of that.
If cron is not a must then take a look at ZopeScheduler product - you will get 
rid of URL fetcher stuff.

-- 
eXt
___
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] Zope3 - where to start?

2006-01-01 Thread eXt

Maciej Zięba wrote:


Hi :)

I'm a total newbie to Zope and I would like to learn it...

Unfortunatelly I can't find any good documentation to start with (it 
could be that I'm a very bad researcher)...



If you were looking for Zope 2 then yes - you are very bad researcher. 
If you were looking for Zope 3.. hmm.. there were some words on this 
list about Zope 3 positioning at zope.org ;)




All of the Zope3 documentation on zope.org is about developing it and 
not about using it :(



No it isn't.



Is there a ZopeBook or something similiar for Zope 3? 



Yes. Just go deeper into Zope 3 section at zope.org

Could you please recommend some place I could start learning it 
(articles, tutorials, etc.)?



For you I'll recommend: http://www.plone.org.pl/resources/ZopeThreeDocs 
(I have to thank you for giving me some motivation to create this page :P)


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