i am new to javascript and am trying to go through tutorials to understand the concepts.
this is my function
function toCelsius(fahrenheit){
(5/9) * (fahrenheit-32);
document.getElementById("demoTemp").onclick.toString();
}
and i am trying to invoke it here:
<form>
<br>
Enter number: <input type="text" name="firstname">
<!-- <input type="text" name="lastname"> -->
<button type="button" onclick="toCelsius()"> new temp in Celsius </button>
</form>
<p id="demoTemp"></p>
i want the user to be able to enter a value and then hit the button that will tell them their new temperature from fahrenheit to celsius