Javascript to Access JPEG Metadata XMP, IPTC, EXIF

Discussion in 'Javascript' started by Reginald Johnson, Apr 22, 2006.

  1. I'm trying display a popup on the mouseover of a jpeg image. I'm
    thinking of trying to populate the popup with text obtained from the
    image metadata. However, I haven't been able to find any information on
    how to do this with javascript. Is there a way to access image metadata
    with javascript.
    Reginald Johnson, Apr 22, 2006
    #1
    1. Advertising

  2. Reginald Johnson wrote:
    > I'm trying display a popup on the mouseover of a jpeg image.
    > I'm thinking of trying to populate the popup with text obtained
    > from the image metadata. However, I haven't been able to find
    > any information on how to do this with javascript. Is there a
    > way to access image metadata with javascript.


    Client-side javascript cannot do that as the browser object models do
    not expose the data contained in image files loaded into Image objects
    or IMG elements. In principle it may be possible to use an XML HTTP
    request object to load an image file and then extract the data from
    the - responseText -, but having image data interpreted as utf-8 encoded
    text and then trying to extract information from the resulting
    javascript string is going to be horrendously difficult. Indeed, it
    would be more practical to have a server-side resource extract the
    information and package it in a form suitable for an XML HTTP request,
    and then request the information indirectly.

    But, if the information is to be extracted on the server it may as well
    be extracted as part of the initial request and included in the page
    that displays the images with the mouseover.

    Richard.
    Richard Cornford, Apr 23, 2006
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. zeng
    Replies:
    0
    Views:
    480
  2. SPE - Stani's Python Editor
    Replies:
    1
    Views:
    328
    Fred Pacquier
    Apr 17, 2008
  3. Jérémy
    Replies:
    8
    Views:
    215
    Jérémy
    Feb 22, 2006
  4. Paul Archer
    Replies:
    2
    Views:
    383
    Paul Archer
    Apr 17, 2009
  5. David Dyer-Bennet
    Replies:
    1
    Views:
    146
    Martin Herrmann
    Nov 15, 2004
Loading...

Share This Page