I am using another form to display this content on the Web. English is displayed well, but Tamil takes some other font display as unknown characters. If I use a font tag before this field then it is ok, but I have check English and Tamil. If I select English, the content should be in English .If select Tamil, the content should be in Tamil. How can I do this?
Requires Free Membership to View
Register today to access targeted resources from our editorial writers and independent industry experts focused on Lotus Domino, Notes, Workplace and other related technologies.
You should be able to do this with Dynamic HTML (DHTML) on the page, using JavaScript and CSS.
Below is a sample function that changes fonts when a link is clicked. To adapt it for your use, change the function calls in the links to pass the name of the fonts that you need to use. Also, make sure the text is enclosed in a DIV or SPAN tag with the ID "Content" (or change the JavaScript function to point to a different HTML element name).
<HTML>
<HEAD>
<SCRIPT>
function SetFont (FontName) {
document.all.Content.style.fontFamily
= FontName;
}
</SCRIPT>
</HEAD>
<BODY>
<A HREF="#" onClick=
"SetFont('Arial')">Set font to Arial</A>
<BR>
<A HREF="#" onClick=
"SetFont('Verdana')">Set font to Verdana</A>
<BR><BR>
<DIV ID="Content">
The font of this text will
change when a link above is clicked.
</DIV>
</BODY>
Do you have comments on this Ask the Expert question and response? Let us know.
This was first published in February 2005