[Zope] Metal:fill-slot *always* returns a <span>?

Doyon, Jean-Francois Jean-Francois.Doyon at CCRS.NRCan.gc.ca
Fri May 5 17:47:23 EDT 2006


Hi there,

I have a "master template" with a slot definition like this:

            <!-- Main Content Area is HERE -->

            <div metal:define-slot="main"></div>

            <!-- Main Content Area ends HERE -->

And another template which attempts to fill it with something like:

<div metal:fill-slot="main" tal:define="childtopics python:
here.aq_parent.getChildTopics();
                                        childmaps python:
here.aq_parent.getChildMaps();
                                        topicmode python: len(childtopics) >
0;">
<h1 tal:content="here/Title"></h1>

Now for some reason I can't figure out, the end result ALWAYS has <span>
tags surrounding the content of the slot, despite the fact I say here they
shoul dbe "div"'s ...

            <!-- Main Content Area is HERE -->

            <span>

<h1>Freshwater</h1>


I've tried other things like:

            <div metal:define-slot="main" />

Or

            <metal:define-slot metal:define-slot="main" />

But no matter what I do, there's a span, even when everything says "div".

This is a problem because the end HTML does not validate, and I work in a
rather large organization that requires it's HTML content to validate ...

I've tried looking through the TAL/PageTemplates code, but without much
success ...

What am I missing here? Is this a bug/misfeature?  Could any one point to
the source code that handles this?

Thanks,

Jean-François Doyon
Internet Service Development and Systems Support / Spécialiste de
dèveloppements internet et soutien technique
Canada Centre for Remote Sensing/Centre Canadien de télédétection
Natural Resources Canada/Ressources Naturelles Canada
http://atlas.gc.ca
Tel./Tél.: (613) 992-4902
Fax: (613) 947-2410


More information about the Zope mailing list