Compare commits
No commits in common. "2c6311ad88740cf2b9d81acaf74a78444079b95d" and "49f59d0f86b25f9af9eed5ec0ec6f8c714b2e962" have entirely different histories.
2c6311ad88
...
49f59d0f86
17
index.html
17
index.html
|
@ -3,7 +3,7 @@
|
|||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="author" content="Arnau Busom i Vidal">
|
||||
<title>Currency Converter</title>
|
||||
<title>Conversor</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
|
@ -13,11 +13,6 @@
|
|||
<option value='SEK'>SEK</option>
|
||||
<option value='JPY'>JPY</option>
|
||||
<option value='GBP'>GBP</option>
|
||||
<option value='INR'>INR</option>
|
||||
<option value='ISK'>ISK</option>
|
||||
<option value='DKK'>DKK</option>
|
||||
<option value='RON'>RON</option>
|
||||
<option value='NOK'>NOK</option>
|
||||
</select>
|
||||
|
||||
<input type='number' id='val' step='0.01'>
|
||||
|
@ -28,19 +23,13 @@
|
|||
<option value='SEK'>SEK</option>
|
||||
<option value='JPY'>JPY</option>
|
||||
<option value='GBP'>GBP</option>
|
||||
<option value='INR'>INR</option>
|
||||
<option value='ISK'>ISK</option>
|
||||
<option value='DKK'>DKK</option>
|
||||
<option value='RON'>RON</option>
|
||||
<option value='NOK'>NOK</option>
|
||||
</select>
|
||||
|
||||
<button onClick='convert()'>Convert</button>
|
||||
|
||||
<p>
|
||||
Converted: <span id='res'></span>
|
||||
Quantitat convertida: <span id='res'></span>
|
||||
</p>
|
||||
|
||||
<button onClick='convert()'>convertir</button>
|
||||
|
||||
<script src='script.js'></script>
|
||||
</body>
|
||||
|
|
|
@ -13,5 +13,5 @@ async function convert(){
|
|||
coef = 1;
|
||||
}
|
||||
var val = document.getElementById('val').value;
|
||||
document.getElementById('res').textContent = Number((val*coef).toFixed(2)).toLocaleString('en') + ' ' +document.getElementById('curr2').value;
|
||||
document.getElementById('res').textContent = val*coef + ' ' +document.getElementById('curr2').value;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user