Gmail is going to be more social! New features coming?!?
Just released my Google chrome extension that save your tabs for the next time you start http://bit.ly/cf8Ejo
RT @newsycombinator: The iPad Big Picture http://bit.ly/ci8wcR
RT @dhh: Stanford crew is fast. The talk from just a few hours ago is already online: http://bit.ly/7NE9WG — Unlearn Your MBA!
..crisscross businesses..
Jan 15
..crisscross businesses..
Oggi ho scoperto che sui voli Ryanair è possibile usare il proprio telefono… ma da quando?
Something is changing in the PE market… Private equity faces fundraising battle – http://tinyurl.com/y9oc3pg
This is a little trick to use the rails plugin “will_paginate” with ajax and classic prototype rails helpers that I used on Kontup. Naturally you should start from here:
http://wiki.github.com/mislav/will_paginate
and follow the classical installation steps. After that you could do in this easy way:
in your controller:
@posts = Post.paginate :page => params[:page]
if params[:page] == nil || params[:page].to_i == 1
@previousPage = nil
@nextPage = 2
else
@previousPage = params[:page].to_i - 1
@nextPage = params[:page].to_i + 1
end
and in your view the links will be:
<% if @previousPage != nil %>
<%= link_to_remote '« Previous', :url => { :action => "indexAJAX", :page => @previousPage }, :update => "content" %> Page <%= @previousPage %> of <%= @posts.total_pages.to_i %>
<% else %>
Page 1 of <%= @posts.total_pages.to_i %>
<% end %>
<% if @nextPage <= @posts.total_pages.to_i %>
<%= link_to_remote 'Next »', :url => { :action => "indexAJAX", :page => @nextPage }, :update => "content" %>
<% end %>
I know that there is a smart way to write this code, so please comment here!
@GL purtroppo il negozio sulla 5th mi manca! Però i primi di gennaio sono a Londra per shopping.. Naturalmente passando per l’Apple store..
@GL fantastica!!
Dec 23
@GL fantastica!!