1 2 3 4 5 ··· 8 下一页
摘要: methods: { itemClick() { this.$router.push(this.path).catch(err => err); } } 在点击事件后面加 catch( err => err) 重复点击后就 不会再报错了 阅读全文
posted @ 2021-01-24 17:36 闭上耳朵 阅读(81) 评论(0) 推荐(0) 编辑
摘要: <body> <!-- select(选择的意思)标签里面要包含 option (选项的意思)。 在option 里面定义 selected=“selected”时 当前页面为默认选项 如下--> <form> <select> 籍贯: <option>湖南</option> <option>湖北< 阅读全文
posted @ 2021-01-16 22:03 闭上耳朵 阅读(128) 评论(0) 推荐(0) 编辑
摘要: <body> <!-- 当点击label标签里面的文字,浏览器自动将光标定在选择的文本上。 label里面的 for 的属性要和input里面的 id 属性一样,如下--> <form> <label for="nan">男</label><input type="radio" name="o" i 阅读全文
posted @ 2021-01-16 21:41 闭上耳朵 阅读(78) 评论(0) 推荐(0) 编辑
摘要: <body> <h1>喜欢的水果</h1> 无序标签&lt; ul &gt;是无序标签的列表 &lt; li &gt;写列表内容,ul 里面只能写li 标签; <ul> <li>榴莲</li> <li>荔枝</li> <li>菠萝</li> <li>山竹</li> </ul> <h1>喜欢的食物</ 阅读全文
posted @ 2021-01-16 21:39 闭上耳朵 阅读(57) 评论(0) 推荐(0) 编辑
摘要: <body> <!-- form是表单标签,就是把表单框起来,input输入的意思 type是类型 --> <!-- "password"是输入密码的 --> <form> 密码: <input type="password"> </form> <!-- text 可以输入的文字 设置value是打 阅读全文
posted @ 2021-01-16 21:38 闭上耳朵 阅读(79) 评论(0) 推荐(0) 编辑
摘要: <title>07.Ajax.post</title> <script src="myAjax2.js"></script> <script> window.addEventListener('load', function() { var btn = document.querySelector( 阅读全文
posted @ 2021-01-12 14:53 闭上耳朵 阅读(69) 评论(0) 推荐(0) 编辑
摘要: <!-- 引入自己封装的 Ajax文件 测试下怎么用 --> <script src="myAjax.js"></script> <script> window.addEventListener('load', function() { var btn = document.querySelecto 阅读全文
posted @ 2021-01-12 14:48 闭上耳朵 阅读(32) 评论(0) 推荐(0) 编辑
摘要: <script> // 问题1:所有浏览器都支持Ajax 除了IE5 IE6 如果让所有浏览器都支持就加上以下代码 13 - 18行 window.addEventListener('load', function() { var btn = document.querySelector('butt 阅读全文
posted @ 2021-01-12 14:46 闭上耳朵 阅读(49) 评论(0) 推荐(0) 编辑
摘要: <!-- 1. 什么是Ajax? AJAX 是与服务器交换数据并更新部分网页的艺术,在不重新加载整个页面的情况下。 --> <script> window.addEventListener('load', function() { var btn = document.querySelector(' 阅读全文
posted @ 2021-01-12 14:44 闭上耳朵 阅读(101) 评论(0) 推荐(0) 编辑
摘要: <body> <form action="03.post.file.php" method="POST" enctype="multipart/form-data"> <!-- 用表单上传文件 必须添加这个属性: enctype="multipart/form-data" 后端才能拿到这个文件 -- 阅读全文
posted @ 2021-01-12 14:42 闭上耳朵 阅读(81) 评论(0) 推荐(0) 编辑
1 2 3 4 5 ··· 8 下一页