some fixes to black colorscheme

This commit is contained in:
Dmitriy Zaporozhets 2011-11-30 23:25:39 +02:00
parent 6686834c8d
commit 46e77db099
2 changed files with 5 additions and 4 deletions

View file

@ -16,11 +16,12 @@ module ProjectsHelper
nil
end
# expires in 360 days
def switch_colorscheme_link(opts)
if cookies[:colorschema].blank?
link_to_function "paint it black!", "$.cookie('colorschema','black'); window.location.reload()", opts
link_to_function "paint it black!", "$.cookie('colorschema','black', {expires:360}); window.location.reload()", opts
else
link_to_function "paint it white!", "$.cookie('colorschema',''); window.location.reload()", opts
link_to_function "paint it white!", "$.cookie('colorschema','', {expires:360}); window.location.reload()", opts
end
end
end