Results 1 to 1 of 1

Thread: Remove Text from XHTML and Make XML

Threaded View

  1. #1

    Thread Starter
    PowerPoster
    Join Date
    Jul 2001
    Location
    Tucson, AZ
    Posts
    2,166

    Remove Text from XHTML and Make XML

    I have some HTML files I've converted to XHTML using Tidy.

    Now I want to strip the text from the XHTML and make the text XML such that the XML looks like:

    VB Code:
    1. <FUNCTION>
    2.     <NAME>
    3.     </NAME>
    4.     <DESCRIPTION>
    5.     </DESCRIPTION>
    6.     <DECLARATION>
    7.     </DECLARATION>
    8.     <OS>
    9.     </OS>
    10.     <LIBRARY>
    11.     </LIBRARY>  
    12.     <PARAMETERS>
    13.     </PARAMETERS>
    14.     <RETURNS>
    15.     </RETURNS>    
    16.     <EXAMPLES>
    17.     </EXAMPLES>
    18.     <RELATED>
    19.     </RELATED>
    20. <FUNCTION>

    QUESTION:

    What would be the best way to move the text to the above XML format -- using XSL or VB?

    If XSL, how do I go about getting the XSL to ignore everything other than the text which is deeply embedded in the HTML?

    Stated another way --

    If the text is embedded deep in the node, such that there are multi <table> </table> tags before getting to the text of interest, what is the fastest way to skip over these <table> tags until I get to the one that contains the text?

    THanks
    David
    Last edited by dw85745; Nov 17th, 2004 at 08:03 AM.

Posting Permissions

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



Click Here to Expand Forum to Full Width