I have made some new content type using Dexterity. I now wish to create the content from a python script. All is well with the line below, and the item is generated in the target folder with the correct id and date. But how do you pass the file data to a file field, the image data to the image field and the richt_text data to the rich_text field?
target.invokeFactory(type_name="content_type_name", id=id, date=date, file=file, image=image, rich_text=rich_text)
The date I could figure out; Dexterity wants the Python datetime format:
datetime.datetime(2011,1,1)
Thank you very much for your help - I am sure I am missing something quite elementary here, but haven't found it - probably because I am looking in the wrong place.