[Zope-CMF] Objects in portal_skins
Gitte Wange
gitte@mmmanager.org
Tue, 24 Jun 2003 14:44:08 +0200
Tirsdag 24 juni 2003 07:31 skrev Bert Vanderbauwhede:
> On Mon, 23 Jun 2003, Dieter Maurer wrote:
> > Bert Vanderbauwhede wrote at 2003-6-23 16:40 +0200:
> > > How can I check if an object is (physically) located in portal_skins?
> >
> > I use the "Find" tab in "portal_skins" for this purpose.
>
> I was thinking of something I could use as a test in a script or template.
> Methods like absolute_url() give me no indication if an object is located
> in portal_skins or one of its subfolders.
>
>
> Bert Vanderbauwhede...
Hi Bert,
I have some code I use to find objects that are not cataloged by
portal_catalog.
It looks like this:
portal = getToolByName(self, 'portal_url').getPortalObject()
findres = self.PrincipiaFind(portal, obj_metatypes=self.listLayoutTypes(),
search_sub=1)
res = []
for findtuple in findres:
parent = findtuple[0]
obj = findtuple[1]
res.append(obj)
return res
Instead of the portal object you should use the portal_skins object
And then insert the meta_type of the PageTemplate ..
Hope it helps ...
--
Gitte Wange
Technical Manager
Email: gitte@mmmanager.org
Web: http://www.mmmanager.org
Tlf: +45 36 46 20 02
This guy is quite far up his own arse :-)
-- Chris Withers
on an article "Why Not Zope?", 30 Nov 2000