I know there are other questions on this site, but I can't get their suggestions to work for me.
I have some JavaScript:
displayString = 'Text to go on line 1'+'<br/>'+'Text to go on line 2'; This appears on my webpage as it should, except there is no line break, and it just appears as:
"Text to go on line 1<br/>Text to go on line 2" I have tried '/n' too, but that seems to just be omitted.
Actual JavaScript:
$(document).ready(function(){ $('#selectDirect').change(function(){ if ($(this).val() === "450 Litre"){ displayString = '450 Litre Vessel'+'<br/>'+'Combination Valve'; } else if ($(this).val() === "550 Litre"){ displayString = '550 Litre Vessel'+'<br/>'+'Combination Valve'; } $("#choiceDisplay").text(displayString); });