Brian Dunning's FileMaker Custom Functions

@GetAsHTMLDecoded ( text )

HTML Character Entity Decoder

  Average rating: 5.0 (2 votes) Log in to vote

Alex Zueiv   Alex Zueiv
Tashkent

Share on Facebook Share on Twitter

  Sample input:
@GetAsHTMLDecoded ( "Hello Мир!" )
  Sample output:
Hello Мир!

  Function definition: (Copy & paste into FileMaker's Edit Custom Function window)

Recursive function for decoding HTML Character Entities.

This CF supports decimal and hexadecimal entity numbers of the whole Unicode table (x0…10FFFF). For compatibility with old systems, entity numbers in the range x80…9F are interpreted as in Windows-1252 (€‚ƒ\„…†‡ˆ‰ etc.)

The CF contains 1448 case-sensitive entity names with 583 synonyms from:

https://dev.w3.org/html5/html-author/charref

So, it is very large (>23K characters), which is yet a bit less than FMP allows (30K). In spite of the size it works quite fast – over 5К substitutions in less than a second.

 

Comments

Log in to post comments.

 

Note: these functions are not guaranteed or supported by BrianDunning.com. Please contact the individual developer with any questions or problems.

Under construction. Email me your wish list for improvements.