Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html>
- <html lang="ro">
- <html>
- <head><title>Test cu jquery</title>
- <style>
- </style>
- <script>
- var cuvant, cuvant1;
- var nr_erori, numar_maxim_erori = 5;
- function Init(){
- cuvant = "romania".toUpperCase();
- cuvant1 = cuvant;
- for (var i=1; i<=cuvant1lenght; i++)
- {
- cuvant1[i] = '*';
- console.log(cuvant1[i]);
- }
- nr_erori = 0;
- $('#cuvant').html(cuvant1);
- }
- function Ghicire(){
- var t=$('#litera').val();
- if(t.lenght == 0)
- {
- return false;
- }
- }
- </script>
- </head>
- <body>
- <div>
- <h1 id="cuvant"></h1>
- <form id="ghicire_litera" onsubmit="return Ghicire();">
- <labe for="litera"> Litera </label>
- <input type="text" id="litera" size="2">
- <button type="submit">?</button>
- </form>
- </div>
- <script>
- $(document).ready(function() {
- Init();
- });
- </script>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement