Widget:PE calculator: Difference between revisions

Jump to navigation Jump to search
Matt Pijoan (talk | contribs)
No edit summary
Matt Pijoan (talk | contribs)
No edit summary
Line 25: Line 25:
}
}
document.forms["PECalc"]["result"].value = score;
document.forms["PECalc"]["result"].value = score;
if(score < 2){document.forms["PECalc"]["longaswer"].value = "DDimer";}
if(score < 2){document.forms["PECalc"]["longanswer"].value = "DDimer";}
if(score >= 2 && score <= 6){document.forms["PECalc"]["longaswer"].value = "OBAUgaagd";}
if(score >= 2 && score <= 6){document.forms["PECalc"]["longanswer"].value = "OBAUgaagd";}
if(score > 6){document.forms["PECalc"]["longaswer"].value = "You gonna die.";}
if(score > 6){document.forms["PECalc"]["longanswer"].value = "You gonna die.";}
}
}
</script>
</script>
Line 41: Line 41:
</table>
</table>
Score: <input type="text" name="result" /><br />
Score: <input type="text" name="result" /><br />
<textarea name="longanswer"></textarea>
<input type="text" size="35" name="longanswer" />
</form>
</form>
</includeonly>
</includeonly>

Revision as of 18:06, 11 May 2012