Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <script type="text/javascript">
- function IsEmpty(){
- if(document.forms['frm'].dienthoai.value.length < 10 || document.forms['frm'].dienthoai.value.length > 13 )
- {
- alert("Bạn chưa điền hoặc sai số điện thoại");
- }
- else if(document.forms['frm'].hoten.value === "")
- {
- alert("Bạn chưa điền họ tên");
- }
- else if(document.forms['frm'].diachi.value === "" || document.forms['frm'].diachi.value === "Số: , đường: , Phường/Xã: , Quận/Huyện: , TP/Tỉnh:")
- {
- alert("Bạn chưa điền địa chỉ giao hàng hoặc địa chỉ quá ngắn");
- }
- else
- {
- //return true;
- //$(document).ready(function(){
- //$("#done-btn").on("click", function(e) {
- // e.preventDefault();
- // $(".container").addClass("prevent-load");
- // if you want to pass data BACK to ChatFuel,
- // then uncomment this and post the data
- // to broadcast-from-webview.php
- $.ajax({
- type: 'POST',
- url: 'broadcast.php',
- data: $('form').serialize(),
- dataType: 'json',
- success: function(data) {
- MessengerExtensions.requestCloseBrowser();
- }
- });
- // If you want to just close the webview,
- // then leave this uncommented
- //MessengerExtensions.requestCloseBrowser();
- //});
- //});
- }//return true;
- }
- </script>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement