|Anonymous | Login | Signup for a new account||2018-12-15 23:05 CET|
|Main | My View | View Issues | Change Log | Roadmap | Docs|
|Viewing Issue Simple Details|
|ID||Category||Severity||Reproducibility||Date Submitted||Last Update|
|0002007||[JEDI VCL] 00 JVCL Components||feature||always||2004-07-28 06:13||2004-09-25 02:20|
|Summary||0002007: HTMLParser eventless tag parsing|
It would be great if the HTML Parser component could parse the page in a loop rather than using events to grab the tags.
And also output easily usable tag properties.
While HtmlParser.DoParse do
if HtmlParser.HtmlTag.Caption = 'input' then
That would loop until the we reach the EOF.
Sometimes you really need to do the parsing and only then start using the results, unlike the current method which is even driven, and still makes you do a bit of parsing yourself (parse attribues yourself).
|Tags||No tags attached.|
|Attached Files||JvHTMLTagParser.zip [^] (17,324 bytes) 2004-08-04 15:18|
|I've attached a very simple tag parser to this post. Try it out and see if it works for you. I only just whipped it together quickly and haven't spent more than 15 minutes on it, so it could probably be improved a lot but it should work nicely as a starting point.|
I've attached an updated JvHTMLTagParser including a demo that shows its use.
Note that the parser doesn't really differentiate between different tag types (i.e start tags, end tags, comments, processing instructions etc) but just output them as is. The demo shows how you can handle these situations easily.
In addition, note that any tag type can have content since the content is parsed after seeing a ">" in the input stream up until the next "<".
|thanks peter3, I've tried the demo and it worked ;)|
|2004-07-28 06:13||anonymous||New Issue|
|2004-08-04 07:27||user72||File Added: JvHTMLTagParser.pas|
|2004-08-04 07:29||user72||Note Added: 0004927|
|2004-08-04 14:44||user72||File Deleted: JvHTMLTagParser.pas|
|2004-08-04 14:44||user72||File Added: JvHTMLTagParser.zip|
|2004-08-04 14:53||user72||Note Added: 0004931|
|2004-08-04 15:18||user72||File Added: JvHTMLTagParser.zip|
|2004-08-04 15:18||user72||File Deleted: JvHTMLTagParser.zip|
|2004-08-05 11:58||anonymous||Note Added: 0004938|
|2004-09-25 02:20||user72||Status||new => resolved|
|2004-09-25 02:20||user72||Resolution||open => fixed|
|2004-09-25 02:20||user72||Assigned To||=> user72|
|Mantis 1.1.6[^] Copyright © 2000 - 2008 Mantis Group|