Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $(function () {
- $('#logout_box').on('click', function (e) {
- $.ajax({
- type: 'post',
- url: 'logout.php',
- success: function ( msg ) {
- document.getElementById('response').innerHTML = msg;
- if(msg.includes("erfolgreich")){
- window.location.reload();
- }
- }
- });
- });
- });
- $(function () {
- $('#loginform').on('submit', function (e) {
- e.preventDefault();
- $.ajax({
- type: 'post',
- url: 'logincheck.php',
- data: "username=" + document.getElementById("username_field").value + "&password=" + document.getElementById("password_field").value,
- success: function ( msg ) {
- document.getElementById('response').innerHTML = msg;
- if(msg.includes("Erfolgreich")){
- window.location.reload();
- }
- }
- });
- });
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement