2016-05-12 8 views
-1

ユーザがエスケープ警告をクリックしたときに閉じるべきではありません。今すぐ支払うボタンをクリックしてさらに移動してください。エスケープボタンをクリックすると甘い警告が閉じないはずです

if($unpaid==true){ 
    echo $print = '<script> 
     function alertOn(){ 
swal({ 
     title: "No Membership Fees Received", 
     text: "Please pay membership fees as per your selected package", 
     type: "warning", 
     confirmButtonText: "PAY NOW" 

     }, 
     function(){ 
     window.location.href = "unpaid.php"; 
    }); 
}; 
window.onload = alertOn 
</script>'; 
+0

溶液で誰もがそこにあります – vivek

答えて

1
  if($unpaid==true){ 
      echo $print1 = '<script> 
      function alertOn(){ 
       swal({ 
        title: "No Membership Fees Received", 
        text: "Please pay membership fees as per your selected package", 
        type: "warning", 
        confirmButtonText: "PAY NOW", 
        **allowEscapeKey:false** 

        }, 
        function(){ 
        window.location.href = "unpaid.php"; 
       }); 
      }; 
      window.onload = alertOn; 
     </script>'; 

    } 
関連する問題