How to structure HTML text (tags and attributes) for processing in LiveCode?

Jim Ault jimaultwins at yahoo.com
Sun Jun 12 17:24:25 EDT 2011


On Jun 12, 2011, at 1:15 PM, Keith Clarke wrote:
> I am a LiveCode novice (<1 year, so still a Rookie!). So, part of  
> the challenge with LiveCode (and indeed, software development in  
> general for me) is understanding the art of the possible.



If you have a URL, I could give some concrete examples of good steps  
to consider.
The reality is that there are different ways that become easier  
depending on the structure of the html.

If the page is a catalog or inventory page, there are lots of  
repeating blocks of code.  If it is a set of tables, nested tables, or  
other cellular structure, then the approach should be different.

If it is mostly text blocks in <p> <div> without links, or with <a>  
tags, again can change the structure of your repeat loops.

One approach is to keep replacing the html strings with delimiters,  
such as tab, cr, ~, or a run of chars such as "MMMM" and then pase the  
resulting text block.  There are almost too many ways to do this.  The  
key is to those that fit together, rather than try to mix and match  
combinations of all of them.

This is usually a very confusing puzzle, since html offers so many  
variations and exceptions.

Hope this helps rather than add to the confusion.

Jim Ault
Las Vegas






More information about the use-livecode mailing list