当前位置: 首页 > news >正文

北京网站建设迈程网络全球知名购物网站有哪些

北京网站建设迈程网络,全球知名购物网站有哪些,莱芜网站推广,漳州建设网站由于是1.8.x#xff1b;圣经的1.9.3差太多,所以另外按1.8.X来创建hello world 第一個Hello World!! 1. 创建项目rails -d mysql first 2。创建控制器 cd first ruby script/generate controller hello 3.创建交互动作 vi app/controllers/hello_controller.rb 修改为 …   由于是1.8.x圣经的1.9.3差太多,所以另外按1.8.X来创建hello world   第一個Hello World!! 1. 创建项目rails -d mysql first 2。创建控制器  cd first ruby script/generate controller hello 3.创建交互动作 vi app/controllers/hello_controller.rb  修改为 class HelloController ApplicationController   def there   end end 4.创建对应动作的view层 vi app/views/hello/there.rhtml h1Hello, World!/h1 5.此时启动服务器 ./script/server  5.前端访问 http://192.168.60.128:3000/hello/there 报错 Errno::ENOENT in HelloController#there No such file or directory - /tmp/mysql.sock  解决 安装mysql之后   service mysqld start 解决办法 ln -s /var/lib/mysql/mysql.sock /tmp/mysql.sock 遇到问题 #42000Unknown database first_development 解决办法 [rootlocalhost /]# mysql Welcome to the MySQL monitor.  Commands end with ; or \g. Your MySQL connection id is 4 Server version: 5.1.52 Qihoo.com   Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved. This software comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to modify and redistribute it under the GPL v2 license   Type help; or \h for help. Type \c to clear the current input statement.   mysql create database first_development; Query OK, 1 row affected (0.00 sec) 终于TMD访问成功 总结 1.由于ruby on rails的架构必须关联数据库用 rails  first 创建会默认关联 sqlite库。去掉 database.yml也报错 2.用rails -d mysql first创建会在config/database.yml中写下 # MySQL.  Versions 4.1 and 5.0 are recommended. # # Install the MySQL driver: #   gem install mysql # On Mac OS X: #   sudo gem install mysql -- --with-mysql-dir/usr/local/mysql # On Mac OS X Leopard: #   sudo env ARCHFLAGS-arch i386 gem install mysql -- --with-mysql-config/usr/local/mysql/bin/mysql_config #       This sets the ARCHFLAGS environment variable to your native architecture # On Windows: #   gem install mysql #       Choose the win32 build. #       Install MySQL and put its /bin directory on your path. # # And be sure to use new-style password hashing: #   http://dev.mysql.com/doc/refman/5.0/en/old-client.html development:   adapter: mysql   encoding: utf8   database: first_development   username: root   password:   host: localhost   # Warning: The database defined as test will be erased and # re-generated from your development database when you run rake. # Do not set this db to the same as development or production. test:   adapter: mysql   encoding: utf8   database: first_test   username: root   password:   host: localhost   production:   adapter: mysql   encoding: utf8   database: first_production   username: root   password:    host: localhost 说明当前开发时使用的是development库上线后可以改用 production 库具体怎么设置还没学习到
http://www.huolong8.cn/news/108103/

相关文章:

  • 广州网站建设乐云seo模板中心外贸流程中有哪些主体单位
  • 网站分站系统网站logo的颜色与网页的颜色
  • 做背景图 网站重庆 建站 价格
  • 网站产品链接怎么做西安php网站建设
  • 信息中心完成网站建设苏州街网站建设
  • 网站建设上机考试题目网站建设怎么入会计账
  • wordpress自动创建子站网页图
  • 赣州房产网站建设网站开发过程会遇到的问题
  • 网站中加入百度地图合肥建设工程竣工结算备案网站
  • 微信安装seo博客
  • 如何制作自己的网站的邮箱wordpress自己写特效
  • 南京模板做网站win10 wordpress安装教程
  • 天津开发区网站建设给微商做网站
  • 网站开发 验收周期免费h5页面制作工具
  • h5可以来做网站吗银川微信网站制作
  • 威海 网站建设公司做网站入什么科目
  • 做网站沈阳网站建设的部署与发布
  • 网站用asp还是php网站后台登陆不进去是怎么回事
  • 西宁市营销网站建设公司游戏加盟招商
  • 购物网站首页源码2017网站建设公司排名
  • 网站建设捌金手指下拉一中国制造货源网一件代发
  • 如何做宣传推广的网站链接网站建设属于什么工作
  • 商城建站服务什么是电子商务网站推广
  • 视频网站的防盗链是怎么做的超级简历模板官网
  • 单县住房和城乡建设局网站简述网站推广的基本方法
  • 彩票黑网站是怎么做的apple官网
  • 微网站建设正规公司c2c网站免费建设
  • 精品课程网站开发有做网站代理运营的吗
  • 中国摄影网站十大排名大型网站的设计
  • 极速网站建设哪家便宜手机推广平台