NB. html.ijs
NB.
NB. tohtml    - convert J text into HTML by replacing characters
NB.             used by HTML with named entities

require 'strings'

NB. =========================================================
NB.*tohtml v convert J text to HTML
tohtml=: 3 : 0
txt=. ,y.
txt=. txt rplc '&';'&amp;'
txt=. txt rplc '"';'&quot;'
txt=. txt rplc '<';'&lt;'
txt=. txt rplc '>';'&gt;'
)
