B4A Question Parseing web pages (the DOM) - Erel (first post)    Mar 21, 2021   (4 reactions) 1. jTidy is a thin wrapper above Tidy library.
2. I don't recommend using SaxParser directly. In most cases it will be much simpler to use Xml2Map which is based on SaxParser.
3. There is a html parser implemented in B4X named MiniHtmlParser. I recommend using this one. B4A Library JTidy library - Convert HTML pages to XML - Erel    Apr 08, 2018   (10 reactions) This library wraps JTidy open source project.
It is supported by B4A and B4J.
It allows you to convert a HTML page to XHTML page. XHTML can be parsed with a XML parser.
This approach is better than trying to parse HTML with regular expressions.
Usage is simple:
Sub Process_Globals
Dim sax As B4A Question How can i show HTML STRING to label.text - Erel (first post)    Jul 19, 2018   (1 reaction) You can use jTidy to convert the html string to a XML document and then parse it with Xml2Map. B4J Question Problem with JTidy (char coding) - rosippc64a (first post)    Oct 05, 2020   (1 reaction) Thank you @Erel , works well! B4J Question JTidy Unknown HTML5 Tags [SOLVED] - Mashiane (first post)    Jan 12, 2018   (1 reaction) Solution:
Copy attached file to your dirassets and...
https://stackoverflow.com/questions/8976637/how-to-add-new-tags-to-jtidy
tid.Initialize
'ensure it shows the output
Dim jo As JavaObject = tid
jo.GetFieldJO("tidy").RunMethod("setForceOutput", Array(True))
File.Copy(File.DirAss B4A Question Subscribe to library updates - Erel (first post)    Oct 13, 2016   (2 reactions) JTidy v1.10 - Fixes an issue with invalid XML output: https://www.b4x.-library-convert-html-pages-to-xml.27038/ B4A Question How to clean invalid HTML to process with DOM parser? - bububrln    Feb 06, 2020 but I could not find a good starting point for that. So, I decided I would like to try it with a DOM parser rather than with SAX, useing the promising XOM library (specification). But since the source document is far from being xhtml, I tried to make it parseable using jTidy. Unfortunately, jTidy cr B4A Question RegEx Matcher with HTML Code - Erel (first post)    Nov 13, 2017   (1 reaction) You should use jSoup or jTidy to parse html. B4A Tutorial [B4X] Text, Strings and Parsers - Erel    May 19, 2020   (20 reactions) This guide is relevant for B4A, B4i and B4J. There are all kinds of tools and libraries available for the different text based formats. The purpose of this guide is to organize the available resources. JSON JSON (B4X) library supports parsing and generating JSON strings. This online tool will hel B4J Question JTidy library - Peter Meares (first post)    Jul 24, 2017 Will do, great service. Thanks Page: 1   2   3   4   5   6   7   Powered by ColBERT |