File: template/js/kontakt-user.js

Recommend this page to a friend!
  Classes of adam berger  >  Separation Database Queries  >  template/js/kontakt-user.js  >  Download  
File: template/js/kontakt-user.js
Role: Auxiliary data
Content type: text/plain
Description: Auxiliary data
Class: Separation Database Queries
Database access trait using PDO
Author: By
Last change:
Date: 3 years ago
Size: 1,920 bytes
 

Contents

Class file image Download
   jQuery(document).ready(function($) {

                $('#form-kontakt').submit(function(e){
				   e.preventDefault();
		$.post('pliki/kontakt-user.php', $(this).serialize(), function(dane) {
			        dane1 = $.parseJSON(dane);
                      //// alert(dane1['blad_ile']);
                        ////console.log("fgdfgdfgdfgdf");
                          var blad_ile  = dane1['blad_ile'];
                                ////alert(blad_ile);
                            if(blad_ile != "blad-zapytania"){      
                            if(blad_ile != 'blad-email'){         
                            if(blad_ile != 'blad'){     
                           if(blad_ile == 'sukces'){ 
                  $('#kontakt').html("<aside class='alert alert-success' style='width:300px;'><p>Wiadomo?? Wys?ana !</p></aside>"); 
                    alert("Wiadomo?? Wys?ana !");				  
		        //location.reload();
                //function loguj(){
              ////window.location.href = 'index.html';
                       //  }
                 //setTimeout(function(){windows.location.reload();},1000);
            }
                    }else{
                       $('#kontakt').html("<aside class='alert alert-error' style='width:300px;'><p>B??d!</p></aside>");
                       //alert("Strona zablokowana !");
                   }   

                   }else{
                        $('#kontakt').html("<aside class='alert alert-error' style='width:300px;'><p>B??d e-mail !</p></aside>");
                        alert("B??d e-mail !");
                    }
                   }else{
                       $('#kontakt').html("<aside class='alert alert-error' style='width:300px;'><p>B??d Zapytania mysql !</p></aside>");
                       alert("B??d Zapytania mysql !");
                   }  
                });
		             return false;
	           });  
});

For more information send a message to info at phpclasses dot org.