[EMAIL PROTECTED] wrote: > Can anyone help me with attachments? Maybe you want to share a working > codeexample? Or point me to some more detailed documentation.
http://www.mmbase.org/download/builds/2003-06-03/mmdocs/general/images-and-attachments.html > I upload my file (<mm:setfield name="filename">) and try to retrieve > the attachment with <A href="<mm:attachment/>">. It is not enough to set the field 'filename'. The 'handle' field must be field too (this is easy with mm:fieldinfo combo's, but you can arrange it yourself too). > > In my code this produces the url: > attachment.db?session=cloud_mmbase+document.txt?493 where document.txt > is the value of the titlefield and 493 is the nodenumber. In the mmbase > jsp-editors this same attachment produces the url: attachment.db?493 > and this works. Where does this session-part come from? What am I doing > wrong? What do I have to do to get it working. The session= part is used when logged in. It's odd that there appear two question-marks. Perhaps it was not well tested with attachment-servlet mapped to attachment.db? Try mapping to a different url (e.g. /attachments/*) for the moment (see web.xml). Do you use mmbase 1.6.3? Michiel -- mihxil' Michiel Meeuwissen Mediapark C101 Hilversum +31 (0)35 6772979 []()
