僕が作ったサービス

clanworkz

2013年7月22日月曜日

海外の英語学習サイト

rarejobの先生から英語学習関連のURLを大量にもらったので、ここにメモしておく。

まだ中身は見てないんだけど、やってみたらちょいちょいコメント追加します。

INTERMEDIATE VOCABULARY
http://www.oup.com/elt/global/products/englishfile/upperint/b_vocabulary/
http://www.englishdaily626.com/slang.php?012
http://www.vocaboly.com/vocabulary-test/
http://www.autoenglish.org/vocab.htm
http://elc.polyu.edu.hk/cill/eap/wordlists.htm
http://esl.about.com/od/vocabularyintermediate/Vocabulary_for_Intermediate_Level_English_Learners.htm
http://www.esl-classroom.com/vocabulary/vindex.html
http://www.eslgold.com/vocabulary/high_intermediate.html

INTERMEDIATE GRAMMAR
http://www.englishmedialab.com/intermediatequiz.html
http://www.eslgold.com/grammar/low_intermediate.html
http://www.nonstopenglish.com/allexercises/
http://englishonline.sites.uol.com.br/english/intermediate.htm
http://www.learnenglish.be/
http://web2.uvcs.uvic.ca/courses/elc/studyzone/
http://free-english-study.com/home/grammar-index.html
http://www.eslgold.com/grammar/high_intermediate.html

INTERMEDIATE PRONUNCIATION
http://www.oup.com/elt/global/products/englishfile/upperint/c_pronunciation/
http://elc.polyu.edu.hk/cill/pronunci.htm
http://www.bbc.co.uk/worldservice/learningenglish/grammar/pron/
http://www.learnersdictionary.com/pronex/pronex.htm
http://www.speak-read-write.com/minimalpairs.html
http://esl.about.com/od/speakingenglish/a/a_stressinto.htm
http://www.englishelearning.com/
http://www.autoenglish.org/pronunciation.htm

INTERMEDIATE LISTENING
http://www.ompersonal.com.ar/omaudio/contenidotematico.htm
http://www.ezslang.com/
http://www.dictationsonline.com/
http://www.5minuteenglish.com/listening.htm
http://esl.about.com/od/intermediatelistenin1/Listening_Skills_for_Intermediate_Level_English_Learners.htm
http://esl.about.com/od/podcasts/Podcasts_for_English_Learning_and_Teaching.htm
http://www.esl-lab.com/ http://blabbinit.com/category/podcast/podcast

2013年7月8日月曜日

htmlからbodyタグの中身だけ取得する正規表現【php】

if (preg_match('~]*>(.*?)~si', $text, $body))
{
    echo $body[1];
}



参考サイトはこちら

paperclip エラーメッセージ

大した話ではないのだが、railsでpaperclipを使って画像をアップする際に、どのようにエラーメッセージを設定すればいいのか調べたのでメモ。

てかこのstackoverflowの記事を見ただけなんだけどね。


  def avatar_is_a_image
    if self.avatar?
      if !self.avatar.content_type.match(/image/)
        errors.add(:avatar, "Avatar must be an image")
      end
    end
  end

  def avatar_is_less_than_two_megabytes
    if self.avatar?
      if self.avatar.size > 5.megabytes
        errors.add(:avatar, "Avatar must be less than 5 megabytes in size")
      end
    end
  end


こんなかんじでメソッドを作成してやればOK