title: title, user: user, tel: tel, email: email, body: body, from_url: window.location.href }; var loadingIdx = null; if (window.layer && layer.load) { loadingIdx = layer.load(0, { shade: [0.2, '#000'] }); } $.ajax({ url: '/message/index', type: 'post', dataType: 'json', data: postData, complete: function () { window.__leftInquirySubmitting = false; if (loadingIdx !== null && window.layer && layer.close) { layer.close(loadingIdx); } }, success: function (res) { // 成功 if (res && res.code === 0) { if (window.layer && layer.msg) { layer.msg(res.msg); } else { alert(res.msg); } // 清空表单 $('#user').val(''); $('#tel').val(''); $('#email_content').val(''); $('#body').val(''); return; } // 失败 var errorMsg = (res && res.msg) ? res.msg : 'Submission failed. Please try again!'; if (window.layer && layer.msg) { layer.msg(errorMsg); } else { alert(errorMsg); } }, error: function () { if (window.layer && layer.msg) { layer.msg('Submission failed. Please try again!'); } else { alert('Submission failed. Please try again!'); } } }); }

All Products

(Total 26 Products)

Choose another language
×
English
Français
Deutsch
Português
Español
Italiano
Русский
한국어
日本語
العربية
ภาษาไทย
Tiếng Việt
Türkçe
Bahasa Indonesia
हिंदी
Pilipino
فارسی
Bahasa Melayu
KiSwahili
Polski