TD text value in multiple lines -
Result:
<apex:page > <apex:form> <table> <tr><td> <div id="myDiv"/> </td></tr> </table> <apex:commandButton onclick="myFunction();" value="NextLine" reRender="dummy"/> <apex:outputPanel id="dummy"/> </apex:form> <script> function myFunction() { document.getElementById('myDiv').innerHTML='<apex:outputText escape="false" value="{!$Label.sample}"/>'; //$Label.sample -->This is <strong><font color="#FF0000"></font></strong> Test Label111 <br/> second Line alert('hi'); } </script> </apex:page> |
Result: