B4J Programming Press on the image to return to the main documentation page.

JTidy

List of types:

Tidy

Tidy

Tidy allows you to convert a HTML page to XHTML format and then parse it with XML parser.
Example
Sub Process_Globals
Dim sax As SaxParser
Dim tid As Tidy
End Sub

Sub Activity_Create(FirstTime As Boolean)
tid.Initialize
'parse the Html page and create a new xml document.
tid.Parse(File.OpenInput(File.DirAssets, "index.html"), File.DirRootExternal, "1.xml")
sax.Initialize
sax.Parse(File.OpenInput(File.DirRootExternal, "1.xml"), "sax")
End Sub

Events:

None

Members:


  Initialize

  Parse (In As java.io.InputStream, Dir As String, FileName As String)

Members description:

Initialize
Parse (In As java.io.InputStream, Dir As String, FileName As String)
Parses the given HTML input stream and generates a XHTML file that can be parsed with a XML parser.
Top