" htmlfile @ write-file throw
;
: anchor1 ( -- uniq )
uniq
htmlfilename over +uniq->fn
dup ['] anchor
old>in @ deco 2!
;
: anchor2 ( uniq c-addr u -- )
get-current search-wordlist
0= throw
+xt->uniq
;
: anchorit ( c-addr -- ) \ counted string
anchor1 swap count anchor2 ;
: create-html ( caddr u -- )
2dup preserve to htmlfilename
w/o create-file throw htmlfile !
s" " >>html
s" " >>html
s" " >>html
s" " >>html
s" " >>html
s" " >>html
;
: close-html
s"
" >>html
s" " >html
then
s" " >>html
s"