Dealing with xpath using libxml

Discussion in 'Ruby' started by Vaucher Bastien, Feb 21, 2007.

  1. Hi,

    I m trying to generate a xslt file from xhtml using libxml and when I m
    parsing the xhtml file and look at xpaths i get something ugly like :

    /*/*[2]/*[1]

    I tried to do the same with REXML and i obtained :

    /html/body/p


    When I m parsing xml files it works fine, but with xhtml files xpaths
    are really ugly.

    Does anyone know how to get nicer xpaths with libxml ?

    Thanks for your answers

    --
    Posted via http://www.ruby-forum.com/.
    Vaucher Bastien, Feb 21, 2007
    #1
    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. Ian Gregory
    Replies:
    1
    Views:
    493
  2. Olav
    Replies:
    3
    Views:
    4,205
  3. Bart
    Replies:
    0
    Views:
    786
  4. Alfie Noakes
    Replies:
    4
    Views:
    790
    Alfie Noakes
    Nov 11, 2008
  5. Stanislaw Wozniak
    Replies:
    7
    Views:
    327
    Matt Neuburg
    Aug 3, 2009
Loading...

Share This Page