[Zope-CMF] CMFCTRAddOns? What are addtn'l predicates for?
Sidnei da Silva
sidnei@x3ng.com.br
Wed, 21 Aug 2002 14:47:13 -0300
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Quarta 21 Agosto 2002 14:24, Jeff Kowalczyk wrote:
| "CMFCTRAddons is a collection of Add-on predicates to use with Content Type
| Registry."
|
| Pardon the clueless question, but what will additional predicates be used
| for?
|
| Is a predicate the signature that tells CMF what type of file is being
| uploaded?
Exactly. I created this 'hack' because when downloading, lets say, a News Item
via FTP from the CMF, you get a file with no extension, but with a header
that states that the file is a News Item. However, if you try to upload the
same file on another CMF Site where a file with the same ID doesnt exists,
the CTR doesnt check for this header when sniffing for the type of the file
being uploaded and creates a Document instead of a News Item.
This is a quick hack to check for those headers and return the right content
type. It worked for what i needed to do, but im sure this could be improved.
[]'s
- --
Sidnei da Silva (dreamcatcher) <sidnei@x3ng.com.br>
X3ng Web Technology <http://www.x3ng.com.br>
GNU/Linux user 257852
Debian GNU/Linux 3.0 (Sid) 2.4.18 ppc
The trouble with computers is that they do what you tell them, not what
you want.
-- D. Cohen
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (GNU/Linux)
iD8DBQE9Y9IhjMbPQxgR5X0RAqQmAKDVPpR/K/a/xATUr2D/3/poz3qLJQCfUlIH
HxLTGPeWmWU0W7SXRzEwUh0=
=6bo/
-----END PGP SIGNATURE-----