下面小编就为大家带来一篇前端获取http状态码400的返回值实例。小编觉得挺不错的,现在就分享给大家,也给大家做个参考。一起跟随小编过来看看吧
如下所示:
axios.get("/check_mobile_and_sent_code",{withCredentials:true,params:{mobile:formInline.mobile}}).then(res=>{
console.log(res);
//if(res.result==true){
if (!this.timer) {
this.count = this.TIME_COUNT;
this.show = false;
this.timer = setInterval(() => {
if (this.count > 0 && this.count <= this.TIME_COUNT) {
this.count--;
} else {
this.show = true;
clearInterval(this.timer);
this.timer = null;
}
}, 1000)
}
/
编程基础网
本文标题为:前端获取http状态码400的返回值实例
基础教程推荐
猜你喜欢
- vue在install时node-sass@4.14.1 postinstall:node scripts/build.js错误解决 2023-07-09
- 使用HTML5中postMessage知识点解决Ajax中POST跨域问题 2022-10-17
- 【vue】三种获取input值的写法 2023-10-08
- JavaScript函数this指向问题详解 2023-08-12
- AJAX实现数据的增删改查操作详解【java后台】 2023-02-23
- Ajax实现简单下拉选项效果【推荐】 2022-12-28
- Ajax实现关键字联想和自动补全功能及遇到坑 2023-02-23
- html网页中使用希腊字母的方法 2022-09-21
- JavaScript开发简单易懂的Svelte实现原理详解 2023-08-12
- ajax异步加载图片实例分析 2022-12-18
