摘要: https://www.cnblogs.com/tjyoung/p/6288990.html 阅读全文
posted @ 2018-01-17 19:28 pyj063 阅读(236) 评论(0) 推荐(0) 编辑
摘要: 1安装之后,在对应的bin目录,同级创建data文件,并在data文件中添加db文件 2、连接服务器;bin目录直接调用cmd命令;输入mongod --dbpath d:\mongodb\data\db 回车即可; 出现以下命令就可以了 3、重新再bin目录调用cmd 输入mongo 回车即可执行 阅读全文
posted @ 2018-01-06 12:16 pyj063 阅读(173) 评论(0) 推荐(0) 编辑
摘要: 1、操作步骤--获取code 1、操作步骤--获取openid 1、操作步骤--获取access_token 1、操作步骤--获取unionid 1、操作步骤--获取openid 1、操作步骤--获取access_token 1、操作步骤--获取unionid 阅读全文
posted @ 2018-01-06 11:52 pyj063 阅读(5415) 评论(1) 推荐(0) 编辑
摘要: nodejs开发 express路由与中间件 路由 通常HTTP URL的格式是这样的: http://host[:port][path] http表示协议。 host表示主机。 port为端口,可选字段,不提供时默认为80。 path指定请求资源的URI(Uniform Resource Iden 阅读全文
posted @ 2018-01-05 15:55 pyj063 阅读(4224) 评论(0) 推荐(3) 编辑
摘要: 一、server+router 1、构成基本框架; index.js(运行的主页面)+server.js(服务器页面)+router.js(路由页面) 2、页面详解 2.1、index.js页面 ①分别调用并启用server.js+router.js页面; ②代码详细; var server=req 阅读全文
posted @ 2017-12-29 10:37 pyj063 阅读(621) 评论(0) 推荐(0) 编辑
摘要: 1、indexof()用法 ~indexOf() 方法可返回某个指定的字符串值在字符串中首次出现的位置。 例如: 注释:indexOf() 方法对大小写敏感! 注释:如果要检索的字符串值没有出现,则该方法返回 -1。 2、lastIndexOf() 方法可返回一个指定的字符串值最后出现的位置,在一个 阅读全文
posted @ 2017-12-29 09:24 pyj063 阅读(190) 评论(0) 推荐(0) 编辑
摘要: 出现以下错误时: G:\nodejs\login\node_modules\mongodb\lib\mongo_client.js:797 throw err; ^ TypeError: db.collection is not a function at findRestaurants (G:\n 阅读全文
posted @ 2017-12-28 13:26 pyj063 阅读(929) 评论(0) 推荐(0) 编辑
摘要: https://jingyan.baidu.com/article/d5c4b52bef7268da560dc5f8.html NodeJS+Express+MongoDB http://www.cnblogs.com/best/p/6212807.html 阅读全文
posted @ 2017-12-28 10:25 pyj063 阅读(110) 评论(0) 推荐(0) 编辑
摘要: 针对不同浏览器,背景渐变的兼容问问题! background: -ms-linear-gradient(top, #fff, #0000ff); /* IE 10 */ background:-moz-linear-gradient(top,#b8c4cb,#f6f6f8);/*火狐*/ backg 阅读全文
posted @ 2017-12-28 09:08 pyj063 阅读(320) 评论(0) 推荐(0) 编辑
摘要: 不多说,旧版本使用 db.addUser("root","root") 新版本使用这句会出现这个错误提示 TypeError: db.addUser is not a function : @(shell):1:1 新版本用的是 db.createUser( { user: "test", pwd: 阅读全文
posted @ 2017-12-27 22:26 pyj063 阅读(564) 评论(0) 推荐(0) 编辑