ruby/rails
hahaliu005
这个作者很懒,什么都没留下…
展开
-
The distinguish of module , class when nested in ruby
For Module can't be instance , so can't call it directily , include it to class , new the class and call module.module M1 module M2 class C3 def two p 'this is two' end原创 2013-10-13 10:06:09 · 580 阅读 · 0 评论 -
gem install mysql2 failed in ubuntu
sudo apt-get install mysql-serversudo apt-get install mysql-clientsudo apt-get install libmysql-ruby libmysqlclient-dev原创 2013-11-27 23:01:18 · 641 阅读 · 0 评论 -
rails gem change the source
gem source -l#http://rubygems.org/gem source -r http://rubygems.org/gem source -a http://ruby.taobao.org/原创 2013-11-27 23:04:51 · 845 阅读 · 0 评论 -
Rails captcha in ubuntu system
Use rails scale to init the captcha.I use a gem called simple_captcha , before you use this gem , first you must install the imagemagick , for the save , tap the command below:sudo apt-get install原创 2013-11-29 14:38:16 · 890 阅读 · 0 评论 -
ruby中的异常与变量的初始化
ruby 中异常的处理语法是这样的:原创 2014-05-26 14:06:05 · 627 阅读 · 0 评论 -
ruby send mail
require 'mail'Mail.defaults do delivery_method :smtp, { :address => "smtp.163.com", :port => 25, :user_name原创 2014-10-15 14:42:22 · 712 阅读 · 0 评论