I really lost and don't know what to do. I tried to link the html form in put to a java-script function.
but the problem is I do not know my steps are correct or not. the other thing is how I can show the output on the page.
function fnCountVowels(string) {
var getinput = document.getElementsbyid("Vowel1");
console.log(Vowel1.value);
for (i = 0 < getinput.length; i++) {
chr = getinput.charat(i);
if (Chr == "a" || (chr == "e") || (chr == "i") || (chr == "o") || (chr == "u")) {
getinput = getinput + 1;
}
}
return getinput;
}
<div id="Vowel" class="Tab">
<form action="" id="form" onsubmit="fnCountVowels(string)">
Enter String: <br>
<input id="Vowel1" type="text" name="Enter the string "><br><br>
<button type="submit" onclick"fnCountVowels(string)">Click</button>
</form>