%noscript
  %div.alert.alert-error=t :js_required_html
#cookie_warning.alert.alert-error{:style => "display:none"}
  =t :cookie_disabled_warning
:javascript
  document.cookie = "testing=cookies_enabled; path=/";
  if(document.cookie.indexOf("testing=cookies_enabled") < 0)
  {
    document.getElementById('cookie_warning').style.display = 'block';
  } else {
    document.getElementById('cookie_warning').style.display = 'none';
  }