Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html>
- <div id="main">
- <html lang=it>
- <head align=center><pre>
- ______ ___ ___ ___ ____ _____ ____ ______ ___ _____ ______
- | | / _]| | || \ / ___/ / | | | / _]/ ___/| |
- | | / [_ | _ _ || o )( \_ _____ | o | | | / [_( \_ | |
- |_| |_|| _]| \_/ || _/ \__ || || | |_| |_|| _]\__ ||_| |_|
- | | | [_ | | || | / \ ||_____|| _ | | | | [_ / \ | | |
- | | | || | || | \ | | | | | | | |\ | | |
- |__| |_____||___|___||__| \___| |__|__| |__| |_____| \___| |__|
- -----------------------------------------------------------------------------------
- </pre></head>
- <script>
- function Check_Answer(){ //Funzione per rilevare se la risposta è Vera o Falsa
- Vero__check=document.getElementById("vero").checked;
- Falso_check=document.getElementById("falso").checked;
- }
- function Count_Answer(){ // Funzione che esegue un alert a seconda dello stato della variabile Vero_Check
- if (Vero__check=true){
- alert("Bravo");
- }
- else if (Vero_check=false) {
- alert("Cattivo");
- }
- else{
- alert("non ho capito")
- }
- }
- </script>
- <body>
- <h2 align=center font="Comic Sans MS" size=40>
- Benvenuto nel Test di Personalità. Rispondi alle seguenti domande Vero o Falso.</br>
- ------------------------------------------------------------------------------------
- </h2>
- <form align=right name="domanda1" method="get" onsubmit="return Check_Answer()">
- <p align=left><font face="Comic Sans MS" size=5>1) Sono una persona scontenta e triste</font></br>
- <input type="radio" Id="vero" name="risposta" value="vero"/><font face="Comic Sans MS" size=3>Vero</font>
- <input type="radio" Id="falso" name="risposta" value="falso"/><font face="Comic Sans MS" size=3>Falso</font>
- </p>
- </form >
- <div id="CheckButton">
- <form ><p><input type="submit" value="Invia"onclick="return Count_Answer()">
- </p></form>
- </div>
- </body>
- </html>
- </div>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement