W3C home > Mailing lists > Public > public-rdf-in-xhtml-tf@w3.org > March 2008

Re: foaf:sha1 property with img src=

From: Mark Birbeck <mark.birbeck@x-port.net>
Date: Mon, 31 Mar 2008 13:15:53 +0100
Message-ID: <a707f8300803310515k1d1fabd0t4788fc1cd27d2cbb@mail.gmail.com>
To: "Daniel Renfer" <duck@kronkltd.net>
Cc: public-rdf-in-xhtml-tf@w3.org

Hi Daniel,

> I ran into a similar issue when I was trying to convert my FOAF file into a
> prose XHTML+RDFa document. My problem was, how can I link to an image, but
> also specify the thumbnail version of that image?
> <#me>
>     foaf:depiction     <me.jpg>.
> <me.jpg>
>     foaf:thumbnail    <me-thumb.jpg>.
> It seems like the answer would be the same for both of them. It's a shame I
> can't just put a span inside of <img/>.

This is why @src was made to act like @about and not @resource/@href.
The mark-up you want is this:

  <div about="#me">
    <span rel="foaf:depiction">
      <img src="me.jpg" rel="foaf:thumbnail" resource="me-thumb.jpg" />

By the way, in XHTML 2 @href can appear on any element, and represents
a navigable link. So you might actually reverse what you are saying,
and say t hat the thumbnail is a depiction of you, and that it is a
'thumbnail of' the larger picture:

  <div about="#me">
    <span rel="foaf:depiction">
      <img src="me-thumb.jpg" rev="foaf:thumbnail" href="me.jpg" />

Now the smaller image shows inline in the document, and clicking on it
would yield the larger image.



  Mark Birbeck

  mark.birbeck@x-port.net | +44 (0) 20 7689 9232
  http://www.x-port.net | http://internet-apps.blogspot.com

  x-port.net Ltd. is registered in England and Wales, number 03730711
  The registered office is at:

    2nd Floor
    Titchfield House
    69-85 Tabernacle Street
    EC2A 4RR
Received on Monday, 31 March 2008 12:21:48 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 17:01:56 UTC