* 生活大爆炸(TBBT)
这个美剧被推荐过很多次,最早是Friends6的官方博客说喜欢Friends的人一定会喜欢这个剧,当时没时间去考证。后来记得沙子说过可以看看这个,她觉得太好笑了,当时还是没有时间。再后来从人人里面看见小虫的一个朋友共享了很多相关的材料,不小心看了一眼,紧接着连着看了几集,开始有点不习惯,总觉得不如Friends来的自然,似乎自己的笑点那时候也变得有点高。直到第六集,猛然间有了全新的认识,一发不可收拾开始着迷这种喜剧效果。这些怪人总是有合理而突然的想法,谢耳朵总是诡异而有序,果然如这部美剧的宣传语:天才是另一种性感。

* 咖啡
这一周经历了几个突然的“意识到”,包括前面说的TBBT,其次就是关于咖啡。这阵子每天早上用大袋的蒙牛钙锌兑着雀巢速溶,把它们调和成拿铁式的espresso,这样过了几天,虽然渐渐很痴迷于这种味道,但却有些觉得不过瘾了,再查了查各种关于咖啡的资料,再后来直接上taobao整了咖啡机和磨豆机,买了各种咖啡豆和日本奶泡…呵呵,下周三之前就可以自己调制拿铁和卡布奇诺了~

* 生病
无缘无故,我发誓这是一次无缘无故的感冒…总之有一天下班的公交车上面,我突然“意识到”自己好像嗓子有点烦躁,然后觉得大事可能要不妙了,回来就喝了板蓝根试图将这种不适感压制下去。不幸的是,第二天,我的嗓子彻底坏掉了,连咽口唾沫都变的异常艰难。第三天,我开始不停的打喷嚏偶尔流点鼻涕。直到周末,我总是一会觉得热一会有觉得很冷,比方现在就非常热,满头大汗,但是除了鼻子有点不通以外,竟然没有任何不适和困乏。我在想,难道不抽烟了咽喉在抗议?

* jQuery
这个是关于工作的,值得一提的不是内容本身(jQuery是一个JS库,和我的近期工作有很大关系),而是在我Blog转摘了一篇材料以后,我在篇首放了一个”Note“,里面写道”referenced from”,被JP比较正式的纠正了一下:“抄了就抄了,不要说是引用,这样对作者很不尊重,引用通常指你自己根据原文有所发展“,经这么一纠正,我马上将那个Note该成了“Copied From”。恩,以后要更细心点,不能再引起这样的误会‘

Note: This introduction post to jRails is copied(mirrored) form this link, so that I can bakeup this for advanced learning.

Intro

jRails is a drop-in jQuery replacement for Prototype/script.aculo.us on Rails. Using jRails, you can get all of the same default Rails helpers for javascript functionality using the lighter jQuery library.

News

jRails 0.4 : jQuery 1.5!

jQuery-UI has just gotten a major update to version 1.5 which stabilizes most of the controls and incorporates the Enchant effects library. jRails follows suit with a single js file for jquery-ui that includes both the modules and effects. The default jRails installation includes a compressed jquery-ui js file that includes the basic modules and effects supported by Prototype/Scriptaculous. There are no modifications to this file, so if you’d like to generate your own with additional modules or effects, just pop on over to the jQuery UI site and customize your own.

This release of jRails also adds support for jQuery.noConflict(). Just uncomment the line in the init.rb file and set it to whatever you like. Now you can use jRails with other libraries without causing problems.

Features

jRails provides drop-in functionality for these existing Rails methods.

    • Prototype
    • form_remote_for
    • form_remote_tag
    • link_to_remote
    • observe_field
    • observe_form
    • periodically_call_remote
    • remote_form_for
    • submit_to_remote
    • Scriptaculous
    • draggable_element
    • drop_receiving_element
    • sortable_element
    • visual_effect
    • RJS
    • hide
    • insert_html
    • remove
    • replace
    • replace_html
    • show
    • toggle

Visual Effects

These are the current effects that are included by default in jRails.

Appear

Fade

Puff

BlindDown

BlindUp

BlindRight

BlindLeft

SwitchOff

SwitchOn

SlideDown

SlideUp

DropIn

DropOut

Shake

Pulsate

Squish

Fold

FoldOut

Grow

Shrink

Highlight

How to use

Just install and go! Once installed, the previous Prototype/script.aculo.us helpers will be replaced by jQuery ones. In order for them to function correctly, just include the appropriate javascript files in the head of your page.

<script src="/javascripts/jquery.js" type="text/javascript"></script>
<script src="/javascripts/jquery-ui.js" type="text/javascript"></script>
<script src="/javascripts/jrails.js" type="text/javascript"></script>

You can also use the Rails javascript_include_tag helper with :default to load them automagically.

<%= javascript_include_tag :defaults %>

Install

To install the jRails plugin:

./script/plugin install git://github.com/aaronchi/jrails.git

Then copy the javascript files in the plugin folder to your javascripts directory.

Changelog

  • : Initial Release
  • : Major Effects Updates
  • : jQuery Enchant
  • : jQuery-ui 1.5 and jQuery.noConflict support

Contact

You can post to the jRails group forum and I’ll get back to you as soon as I can

Comments, bug reports and feedback are welcomed. I’m also considering developing a similar library for MooTools so if you are interested, please let me know.

This post is a copy of my work stuff, but I want to archive all the links below, they are all about SEO on Rails application, as well as a useful post about jQuery on Rails.

Finally, we decided to create a Rails App for the EQV2 New Website, so I did several homework for this mission. They are:

1. SEO on Rails.
Several rules/good points for seo according to the following websites:
1> http://www.elctech.com/articles/rails-seo-starter-guide
2> http://www.tonyspencer.com/2007/01/26/seo-for-ruby-on-rails/
3> http://www.seoonrails.com/
4> http://blog.csdn.net/diehuan2008/archive/2009/02/23/3925204.aspx

2. Maybe use JQuery more in EQV2.
1> http://yehudakatz.com/2007/01/31/using-jquery-in-rails-part-i/
2> http://www.slideshare.net/wycats/jquery-presentation-to-rails-developers-110063

3. Cache Views.

MORE IDEAS?

But, first version should be structured well and make sure it’s been done before the “deadline”, so this app will be according to the recommendation but not totally implemented in the best way, in all, it still needs your suggestion.

© 2011 Refactoring Thoughts Suffusion theme by Sayontan Sinha
普人特福的博客cnzz&51la for wordpress,cnzz for wordpress,51la for wordpress