[uf-dev] include-pattern testing

Brian Suda brian.suda at gmail.com
Sat Apr 29 09:40:38 PDT 2006


Thanks for pointing this out. I have two initial thoughts before
digging into this much further.

1) I would avoid changing the .// to descendant-or-self:: because (i
think) that will open-up a bigger problem. With the code, as it
stands, doing descendant-or-self would then make the following valid
(which we want to avoid)

<span class="vcard fn">brian suda</span>

2) The easy fix would be to lobby to change th include-pattern so that
the #ref-id acts like a 'root node' and we only look to the children
of that (the way X2V currently works)

the @header code does something similar, so i am looking into if a
similar fix can be applied to includes, or maybe the @header is broken
as well?

<xsl:value-of select="descendant-or-self::*/@headers"/>

-brian

On 4/29/06, Dan Connolly <connolly at w3.org> wrote:
> Brian and everybody,
>
> The x2v implementation of object/include doesn't seem to match
> the wiki topic http://microformats.org/wiki/include-pattern
>
> x2v only looks for the children of the referenced element,
> not the element itself.
>
> I just made a test out of the example there.
>
> hcard/35-include-pattern.html
> hcard/35-include-pattern.vcf
>
> http://hg.microformats.org/tests
> changeset:   1efe1721cdbe
> date:        Sat Apr 29 09:59:01 2006 -0500
>
> I started working on a fix to x2v; unfortunately, it touches
> a lot of the code. It involves changing .//*[...]
> to descendant-or-self::*[...] in lots of places.
>
> That include pattern is pretty cool. It's a bit of a pain
> to implement, but I think it helps a lot with DRY issues
> that I was running into while trying hResume out on my CV.
>
> --
> Dan Connolly, W3C http://www.w3.org/People/Connolly/
> D3C2 887B 0F92 6005 C541  0875 0F91 96DE 6E52 C29E
>
> _______________________________________________
> microformats-dev mailing list
> microformats-dev at microformats.org
> http://microformats.org/mailman/listinfo/microformats-dev
>


--
brian suda
http://suda.co.uk


More information about the microformats-dev mailing list