I wanted to make sure I hadn't given you bad guidance, so I tried this myself. I used the eventmap tagset to determine that ODS TEXT= strings are surrounded by three events: text_group, text_row, and text. The "value" event attribute in the text event contains the actual TEXT= string. By default those three events add <table>, <tr>, and <td> tags to the html, creating a table with one row and one cell. The cell contains the TEXT= string.
Here's code that captures all three of these events and substitutes some debugging output. Run it and examine the test.html file. (I did this with SAS 9.4M3.)
proc template;
define tagset tagsets.mytagset;
parent = tagsets.html4;
define event text_group;
start:
put 'text_group event start' nl;
ndent;
finish:
xdent;
put 'text_group event finish' nl;
end;
define event text_row;
start:
put 'text_row event start' nl;
ndent;
finish:
xdent;
put 'text_row event finish' nl;
end;
define event text;
start:
put 'text event start' nl;
ndent;
put 'value=' value nl;
finish:
xdent;
put 'text event finish' nl;
end;
end;
run;
ods tagsets.mytagset file="test.html";
ods text = "My text string";
ods text = "Another text string";
proc print data=sashelp.class;
run;
ods tagsets.mytagset close;
... View more