Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 4 of 4
  1. #1
    New Coder
    Join Date
    Jul 2008
    Posts
    64
    Thanks
    12
    Thanked 0 Times in 0 Posts

    Question data island + browser help

    why is my data island code not working with firefox? except for IE7

    here's the screenshot



    and here's my code

    Code:
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
        "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
    
    <html xmlns="http://www.w3.org/1999/xhtml">
    
    <head>
      <title>Hello!</title>
    </head>
    
    <body>
    <xml id="myxmldatasource">
    <items>
        <item id="item1">
            <name>Mocah</name>
            <type>Coffee</type>
            <photo>photos/candles.jpg</photo>
        </item>
        <item id="item2">
            <name>Decaf</name>
            <type>Coffee</type>
            <photo>photos/teacup.jpg</photo>
        </item>
        <item id="item3">
            <name>Raspbery Zinger</name>
            <type>Tea</type>
            <photo>photos/teapot_white.jpg</photo>
        </item>
        <item id="item4">
            <name>Earl Grey</name>
            <type>Tea</type>
            <photo>photos/teapot_bone.jpg</photo>
        </item>
    </items>
    </xml>
    <table datasrc="#myxmldatasource" border="1">
    <thead>
      <tr>
        <th>Photo</th>
        <th>Description</th>
        <th>Type</th>
      </tr>
    </thead>
    <tbody>
      <tr>
       <td>
          <img datafld="photo"/>
       </td>
       <td>
          <span datafld="name"/>
       </td>
       <td>
          <span datafld="type"/>
       </td>
      </tr>
    </tbody>
    </table>
    
    </body>
    
    </html>
    Last edited by capt_nemo777; 11-07-2008 at 10:44 AM.

  • #2
    Master Coder
    Join Date
    Dec 2007
    Posts
    6,682
    Thanks
    436
    Thanked 890 Times in 879 Posts
    Quote Originally Posted by capt_nemo777 View Post
    why is my data island code not working with firefox? except for IE7
    because is not a valid page.

    regards

  • #3
    New Coder
    Join Date
    Mar 2007
    Location
    italy
    Posts
    94
    Thanks
    1
    Thanked 1 Time in 1 Post
    Hi capt_nemo777,

    I'm sorry but XML Data Islands only works with Internet Explorer browsers!!!

    check w3schools for more info about it.

    To do the work you want to do, you should use JavaScript and XML DOM, or CSS.
    (from the link I gave you you can explore more the way to do it)

    ciao

  • #4
    New Coder
    Join Date
    Jul 2008
    Posts
    64
    Thanks
    12
    Thanked 0 Times in 0 Posts
    oh ok.. i'll get into javascript next week


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •