Hello Friends My Name Is Viraj,Today I Will Convert Temperature On Your Web Page.Fahrenheit and centigrade are two temperature scales in use today. The Fahrenheit scale was developed by the German physicist Daniel Gabriel Fahrenheit . In the Fahrenheit scale, water freezes at 32 degrees and boils at 212 degrees.The centigrade scale, which is also called the Celsius scale, was developed by Swedish astronomer Andres Celsius. In the centigrade scale, water freezes at 0 degrees and boils at 100 degrees.Select the unit to convert from in the input units list. Select the unit to convert to in the output units list. Enter the value to convert from into the input box on the left. The conversion result will immediately appear in the output box.Enter a value for any one of the three temperature scales and the others will automatically be calculated. Javascript must be enabled in your web browser for calculations to occur.Significant figures are used. Results are shown only with as many significant figures as the quantity that was entered. Scientific notation may be used for large results or if the number of significant digits would be ambiguous otherwise. The calculator follows proper rounding rules for scientific purposes.The degree converter °C to °F and vice versa is easy to use.
Just enter the temperature in Celsius or Fahrenheit for conversion.This is another School / College program which helps to learn and understand about JavaScript programming. In this example you are going learn to find Celsius from Fahrenheit using pure JavaScript.There are two versions I have actually written for this post, one will allow any characters in text box and the second will allow only numbers.Here In This Html Tutorial We Will Create To Convert Temperature In Html/Css/Javascript Code.Here In This Blog We Will Create To Convert Temperature In Html/Css/Javascript Code.Here Is An Example Related To Topic...............
So Let Begin With Our Coding............
Step 1 :
<!DOCTYPE html>
<html>
<title>Fahrenheit to Celcius Temperature Converter</title>
<body>
<h2>Temperature Converter</h2>
<p>Type a value in the Fahrenheit field to convert the value to Celcius:</p>
<p>
<label>Fahrenheit</label>
<input id="inputFahrenheit" type="number" placeholder="Fahrenheit" oninput="temperatureConverter(this.value)" onchange="temperatureConverter(this.value)">
</p>
<p>Celcius: <span id="outputCelcius"></span></p>
<script>
function temperatureConverter(valNum) {
valNum = parseFloat(valNum);
document.getElementById("outputCelcius").innerHTML=(valNum-32)/1.8;
}
</script>
</body>
</html>
Just enter the temperature in Celsius or Fahrenheit for conversion.This is another School / College program which helps to learn and understand about JavaScript programming. In this example you are going learn to find Celsius from Fahrenheit using pure JavaScript.There are two versions I have actually written for this post, one will allow any characters in text box and the second will allow only numbers.Here In This Html Tutorial We Will Create To Convert Temperature In Html/Css/Javascript Code.Here In This Blog We Will Create To Convert Temperature In Html/Css/Javascript Code.Here Is An Example Related To Topic...............
So Let Begin With Our Coding............
Step 1 :
<!DOCTYPE html>
<html>
<title>Fahrenheit to Celcius Temperature Converter</title>
<body>
<h2>Temperature Converter</h2>
<p>Type a value in the Fahrenheit field to convert the value to Celcius:</p>
<p>
<label>Fahrenheit</label>
<input id="inputFahrenheit" type="number" placeholder="Fahrenheit" oninput="temperatureConverter(this.value)" onchange="temperatureConverter(this.value)">
</p>
<p>Celcius: <span id="outputCelcius"></span></p>
<script>
function temperatureConverter(valNum) {
valNum = parseFloat(valNum);
document.getElementById("outputCelcius").innerHTML=(valNum-32)/1.8;
}
</script>
</body>
</html>
Output :
No comments:
Post a Comment