12 2019 档案

摘要:echarts.init(document.getElementById(id)).setOption({ backgroundColor: '#2c343c', // 背景颜色 textStyle: { color: 'rgba(255, 255, 255, 0.3)', // 文本颜色 font 阅读全文
posted @ 2019-12-31 11:40 GetcharZp 阅读(652) 评论(0) 推荐(0) 编辑
摘要:原因: 微擎后台绑定的小程序与前台小程序不对应; 解决办法: 首先,在微擎后台新建一个与前台小程序对应的后台小程序平台; 然后,修改前台小程序中的 siteinfo.js 文件,使其中的 uniacid 、 acid 与后台平台的ID一致 最后,重新刷新开发者工具就阔以了。 阅读全文
posted @ 2019-12-30 10:42 GetcharZp 阅读(1228) 评论(0) 推荐(0) 编辑
摘要:解决办法: 将该资源文件的引入放在 整个文件的最前面 阅读全文
posted @ 2019-12-26 15:23 GetcharZp 阅读(434) 评论(0) 推荐(0) 编辑
摘要:getSystemInfoSync 获取用户设备的相关信息 示例代码: 使用位置:在 JS文件的任意函数中使用 const res = wx.getSystemInfoSync(); console.log(res); console.log(res.model); // 设备机型 console. 阅读全文
posted @ 2019-12-23 18:16 GetcharZp 阅读(1904) 评论(0) 推荐(0) 编辑
摘要:base64ToArrayBuffer 将 base64 的字符串转化为 ArrayBuffer 对象 示例代码: 使用位置:在 JS文件的任意函数中使用 const base64 = 'CxYh'; console.log(wx.base64ToArrayBuffer(base64)) 阅读全文
posted @ 2019-12-23 18:10 GetcharZp 阅读(2862) 评论(0) 推荐(0) 编辑
摘要:1、在 core/mobile 中添加对应的文件夹和文件 2、访问的路由 : 举个栗子: 当访问链接为: https://getcharzp.cn/app/index.php?i=2&c=entry&m=ewei_shopv2&do=mobile&r=member.esp 的时候, 对应的控制器为 阅读全文
posted @ 2019-12-23 14:30 GetcharZp 阅读(885) 评论(0) 推荐(0) 编辑
摘要:使用说明: 1、回复的内容还是需要自己建表存储起来; 2、通过 Module.php 文件将回复内容相关的操作封装起来 最终效果图: 示例: 1、module.php <?php /** * * @url http://www.we7.cc/ */ defined('IN_IA') or exit( 阅读全文
posted @ 2019-12-20 15:27 GetcharZp 阅读(814) 评论(0) 推荐(0) 编辑
摘要:// 获取浏览器 宽高 var width = window.innerWidth || document.documentElement.clientWidth || document.body.clientWidth var height = window.innerHeight || docu 阅读全文
posted @ 2019-12-19 18:17 GetcharZp 阅读(242) 评论(0) 推荐(0) 编辑
摘要:原因: 可能原因一: 直接通过表工具导出的数据表结构中没有指明主键 修改方式: 在对应的表的小括号内添加 PRIMARY KEY (`主键ID`) 可能原因二: 直接通过表工具导出的数据表结构中没有指明主键自增 修改方式: 将对应的主键设置为自增长 AUTO_INCREMENT 可能原因三: 在表名 阅读全文
posted @ 2019-12-19 15:25 GetcharZp 阅读(268) 评论(0) 推荐(0) 编辑
摘要:// 1、数组拼接 concat() var a = [1, 2]; var b = [3, 4]; console.log(a.concat(b)); // [1, 2, 3, 4] // 2、数组翻转 reverse() var a = [1, 2, 3]; console.log(a.reve 阅读全文
posted @ 2019-12-19 11:52 GetcharZp 阅读(253) 评论(0) 推荐(0) 编辑
摘要:// 函数声明方法一 function f (a, b) { return a + b; } // 函数调用 console.log(f(1, 4)); // 5 // 函数声明方法二 var num = function(a, b) { return a + b; } console.log(nu 阅读全文
posted @ 2019-12-19 11:05 GetcharZp 阅读(142) 评论(0) 推荐(0) 编辑
摘要:// 1、for循环 for (var i = 0; i <= 10; ++ i) { console.log(i); } // 2、while循环 var i = 0; while (i <= 10) { console.log(i); ++ i; } 阅读全文
posted @ 2019-12-19 10:45 GetcharZp 阅读(231) 评论(0) 推荐(0) 编辑
摘要:// 1、if...else if (true) { console.log("TRUE1"); } else { console.log("TRUE2"); } // 2、if...else if...else if (true) { console.log("TRUE1"); } else if 阅读全文
posted @ 2019-12-19 10:41 GetcharZp 阅读(366) 评论(0) 推荐(0) 编辑
摘要:人人商城返回Json格式的数据 1、找到该插件对应的 core/mobile 路径 2、新建一个 api.php 文件 <?php header('Content-Type:application/json; charset=utf-8'); if (!defined('IN_IA')) { exi 阅读全文
posted @ 2019-12-19 10:40 GetcharZp 阅读(602) 评论(0) 推荐(0) 编辑
摘要:// 1、Boolean() console.log(Boolean(123)); // true console.log(Boolean(undefined)); // false console.log(Boolean("false")); // true // 2、流程控制自动转化 var c 阅读全文
posted @ 2019-12-19 09:32 GetcharZp 阅读(338) 评论(0) 推荐(0) 编辑
摘要:// 1、Number() var num1 = Number(true); console.log(num1); // 1 var num2 = Number(" ") console.log(num2); // 0 // 2、parseInt() var num1 = parseInt("12. 阅读全文
posted @ 2019-12-19 09:28 GetcharZp 阅读(4089) 评论(0) 推荐(0) 编辑
摘要:// 1、 toString() var num = 8; var numString = num.toString(); console.log(numString); var result = true; var resultString = result.toString(); console 阅读全文
posted @ 2019-12-19 09:20 GetcharZp 阅读(8050) 评论(0) 推荐(0) 编辑
摘要:简单来说分两步走: 1、配置项目根目录的 app.json 文件中的 navigateToMiniProgramAppIdList { "pages": [ "pages/index/index" ], "navigateToMiniProgramAppIdList": [ "小程序APYID" ] 阅读全文
posted @ 2019-12-17 15:08 GetcharZp 阅读(570) 评论(0) 推荐(0) 编辑
摘要:wx.canIUse(); 微信文档中定义在API中,可以理解为一个函数。 返回值: true 或者 false 示例: // 在JS文件的函数中进行使用 console.log(wx.canIUse('console.log')); // 输出:true 阅读全文
posted @ 2019-12-16 10:33 GetcharZp 阅读(1484) 评论(0) 推荐(0) 编辑
摘要:wxml: data-参数名="值" bindtap="函数名" <view class="buy-button {{cap_select == 100 ? 'zp-active': ''}}" data-cap="100" bindtap="choose_cap"> <text>100ML \n 阅读全文
posted @ 2019-12-12 09:56 GetcharZp 阅读(4837) 评论(0) 推荐(0) 编辑
摘要:不转换成JSON 会报错 Unexpected identifier 方法: JSON.stringify(对象) 阅读全文
posted @ 2019-12-06 16:22 GetcharZp 阅读(594) 评论(0) 推荐(0) 编辑
摘要:微擎form表单进行GET提交时,要传递 name 分别为 c , a , m , do 的值 例如: <form action="{php echo $this->createWebUrl($filename, array('op' => 'display'))}" class="form-inl 阅读全文
posted @ 2019-12-05 11:29 GetcharZp 阅读(373) 评论(0) 推荐(0) 编辑
摘要:修改 app.json 文件即可 "tabBar": { "selectedColor": "#1296db", "list": [ { "pagePath": "pages/index/index", "text": "首页" }, { "pagePath": "pages/setting/set 阅读全文
posted @ 2019-12-04 17:32 GetcharZp 阅读(514) 评论(0) 推荐(0) 编辑
摘要:jquery 中 html与text函数的区别 共同点:它们都能讲函数中的参数渲染到页面中; 异同点: text() 只是简单的讲参数的内容写入到页面中; html() 会根据参数的值,判断是否字体符号之类的,并进行对应的html类型的解析 阅读全文
posted @ 2019-12-03 22:07 GetcharZp 阅读(302) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示