diff options
author | prashantsinalkar | 2018-08-23 10:30:16 +0530 |
---|---|---|
committer | prashantsinalkar | 2018-08-23 10:30:16 +0530 |
commit | 1684b6aad3918228fdcdee2886c29b74d5ef2881 (patch) | |
tree | 08ddf3bd6f38dc5763fc57d35efba4cde61dd375 | |
parent | c21db7ce9d674644bd446c86e4617608577855fb (diff) | |
download | SciPy2018-1684b6aad3918228fdcdee2886c29b74d5ef2881.tar.gz SciPy2018-1684b6aad3918228fdcdee2886c29b74d5ef2881.tar.bz2 SciPy2018-1684b6aad3918228fdcdee2886c29b74d5ef2881.zip |
added character counter
-rw-r--r-- | static/website/js/custom.js | 13 | ||||
-rw-r--r-- | static/website/templates/header.html | 6 |
2 files changed, 19 insertions, 0 deletions
diff --git a/static/website/js/custom.js b/static/website/js/custom.js index 2573428..4720549 100644 --- a/static/website/js/custom.js +++ b/static/website/js/custom.js @@ -65,6 +65,18 @@ $(document) updateGallery($(this)); }); } + + var fewSeconds = 5; + $('#subbtn').click(function(){ + // Ajax request + alert("I have read all the instructions carefully"); + var btn = $(this); + /*btn.prop('disabled', true); + setTimeout(function(){ + btn.prop('disabled', false); + }, fewSeconds*1000);*/ +}); + }); // build key actions @@ -91,3 +103,4 @@ $(document) e.preventDefault(); // prevent the default action (scroll / move caret) }); + diff --git a/static/website/templates/header.html b/static/website/templates/header.html index fe1ffb4..a6b3c50 100644 --- a/static/website/templates/header.html +++ b/static/website/templates/header.html @@ -33,6 +33,12 @@ jQuery(document).ready(function($){ }); </script> + <script> + function countChar(val) { + var len = val.value.length; + var count = $('#charNum').text(0 + len); + }; + </script> </head> {% endblock %} |