Thru the pains of PNG in (IE <img>'ing png icons..
First i've started from HERE.
Go here and read some instructions that are simple ( i dont want to repost them here!)
I've been uploaded updated painless_png.zip completely modified and working to my blog.
With this modifications (by Naixn and some by me) you *dont* need any modification to your css/html/ruby code.
1.Unpack content of ZIP into vendor/plugin
2.Copy blank.gif from ZIP to public/images.
Restart server and enjoy !
DOWNLOAD HERE
botvector.net domain for sale $2k usd (negotiable). Em@il me t0: alex DOT creopolis at gmail DOT com
My Git activity
20 September 2007
Painless PNG plugin MOD
by
Alexey
at
13:44
09 September 2007
What is that ?
by
Alexey
at
13:48
Does anyone can define this function ?
range.inject(Hash.new(0)){|h,e| h[e] += 1; h}
range is array of integers like: [1,22,12,8,45,3,etc..]
02 September 2007
:conditions => ["created BETWEEN...
by
Alexey
at
15:05
Best way to get query by "from" date and "till date" is:
range = "created_at #{(12.months.ago..Time.today).to_s(:db)}"
Will result in creating String = "created_at BETWEEN "03-09-2006" AND "03-09-2007""
AND then
@data = MyModel.find(:all, :conditions => ["code=? AND #{range}", 2])
link_to_back helper
by
Alexey
at
12:49
It will take referer, @params and redirect you back to same page you been before.
Useful then sorting search results, paging, editing different objects via same _form...
This is code for helper file, i prefer application helper.
def link_to_back (description = "Back")
referer = request.env["HTTP_REFERER"]
return false if !referer
getIt = request.env["REQUEST_URI"].split("?")[1]
if getIt.nil?
getIt = ""
else
getIt = "?" + getIt if !getIt.match(/\?/)
end
link_to description, referer + getIt
end
then just do:
<%= link_to_back %> or
<%= link_to_back "Cancel" %>
Subscribe to:
Posts (Atom)