]> git.openstreetmap.org Git - rails.git/blobdiff - app/views/layouts/site.rhtml
Ensure homepage source validates.
[rails.git] / app / views / layouts / site.rhtml
index d2a9e0122fe8d1b31acf195bcf3d8ae44938e55c..7e224b4c6a9f61c1949979c0a3e31982f625e86c 100644 (file)
@@ -11,8 +11,8 @@
   </head>
   <body>
     <div id="content">
-      <% if flash[:notice] %>
-        <div id="notice"><%= flash[:notice] %></div>
+      <% if @notice || flash[:notice] %>
+        <div id="notice"><%= @notice || flash[:notice] %></div>
       <% end %>
 
       <%= yield %>
@@ -43,7 +43,6 @@
         exportclass = 'active' if params['controller'] == 'site' and params['action'] == 'export'
         traceclass = 'active' if params['controller'] == 'trace'
         diaryclass = 'active' if params['controller'] == 'diary_entry'
-        browseclass = 'active' if params['controller'] == 'browse'
         %>
         <li><%= link_to 'View', {:controller => 'site', :action => 'index'}, {:id => 'viewanchor', :title => 'view maps', :class => viewclass} %></li>
         <li><%= link_to 'Edit', {:controller => 'site', :action => 'edit'}, {:id => 'editanchor', :title => 'edit maps', :class => editclass} %></li>
@@ -53,7 +52,7 @@
         <li><%= link_to 'Export', {:controller => 'site', :action => 'export'}, {:id => 'exportanchor', :title => 'export map data', :class => exportclass} %></li>
         <% end %>
         <li><%= link_to 'GPS Traces', {:controller => 'trace', :action => 'list'}, {:id => 'traceanchor', :title => 'manage traces', :class => traceclass} %></li>
-        <li><%= link_to 'User Diaries', {:controller => 'diary_entry', :action => 'list'}, {:id => 'diaryanchor', :title => 'view user diaries', :class => diaryclass} %></li>
+        <li><%= link_to 'User Diaries', {:controller => 'diary_entry', :action => 'list', :display_name => nil}, {:id => 'diaryanchor', :title => 'view user diaries', :class => diaryclass} %></li>
       </ul>
     </div>
 
 
       <% unless @user %>
       <div id="intro">
-        OpenStreetMap is a free editable map of the whole world. It is made by people like you.
-        <p/>
-        OpenStreetMap allows you to view, edit and use geographical data in a collaborative way from anywhere on Earth.
-        <p/>
-        OpenStreetMap's hosting is kindly supported by the <a href="http://www.vr.ucl.ac.uk">UCL VR Centre</a> and <a href="http://www.bytemark.co.uk">bytemark</a>.
+        <p>OpenStreetMap is a free editable map of the whole world. It is made by people like you.</p>
+        <p>OpenStreetMap allows you to view, edit and use geographical data in a collaborative way from anywhere on Earth.</p>
+        <p>
+          OpenStreetMap's hosting is kindly supported by the <a href="http://www.vr.ucl.ac.uk">UCL VR Centre</a> and <a href="http://www.bytemark.co.uk">bytemark</a>.
+        </p>
       </div>
       <% end %>
 
-      <% if API_STATUS == :offline %>
+      <% if OSM_STATUS == :database_offline or OSM_STATUS == :api_offline %>
       <div id="alert">
         The OpenStreetMap database is currently offline while
         essential database maintenance work is carried out.
       </div>
-      <% elsif API_STATUS == :readonly %>
+      <% elsif OSM_STATUS == :api_readonly %>
       <div id="alert">
         The OpenStreetMap database is currently in read-only mode while
         essential database maintenance work is carried out.
       </div>
       <% end %>
 
+      <div id="donate">
+        Support OpenStreetMap by
+        <a href="http://donate.openstreetmap.org/">donating</a>
+        to the Hardware Upgrade Fund.
+      </div>
+
       <div id="left_menu" class="left_menu">
         <a href="http://wiki.openstreetmap.org">Help &amp; Wiki</a><br />
         <a href="http://www.opengeodata.org/">News blog</a><br />