add filters for excluding home projects and debuginfo packages from search results
[opensuse:software-o-o.git] / app / views / layouts / application.rhtml
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
2 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
3   <head>
4     <title>Software.openSUSE.org</title>
5     <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
6     <meta http-equiv="Content-Script-Type" content="text/javascript"/>
7     <meta http-equiv="Content-Style-Type" content="text/css"/>
8
9     <%= stylesheet_link_tag "/css/ui.dialog.css", "/themes/bento/css/style.css", "/css/software.css" %>
10     <link href="http://static.opensuse.org/hosts/software.o.o/images/favicon.ico" rel="shortcut icon" />
11     <%= javascript_include_tag "http://static.opensuse.org/themes/bento/js/jquery.js", "jquery-ui-1.7.2.js", "jrails.js", "application.js"  %>
12     <%= javascript_include_tag "http://static.opensuse.org/c/javascript/common/langsel.js" %>
13     <%= javascript_include_tag "/themes/bento/js/l10n/global-navigation-data-#{@lang}.js", "/themes/bento/js/global-navigation.js" %>
14     <%= javascript_include_tag "http://www.google-analytics.com/ga.js" %>
15
16     <%= yield :content_for_head %>
17
18     <script type="text/javascript">
19     /* <![CDATA[ */
20     <%= yield :head_javascript %>
21     $(function() {
22       <%= yield :ready_function %>
23     });
24     /* ]]> */
25     </script>
26
27   </head>
28   <body>
29
30     <div id="header">
31       <div id="header-content" class="container_12">
32         <a id="header-logo" href="/">
33           <%= image_tag '/themes/bento/images/header-logo.png', :width => 46, :height => 26, :alt => _("Header Logo") %>
34         </a>
35         <ul id="global-navigation">
36           <li id="item-downloads"><a href="http://en.opensuse.org/Sitemap#downloads"><%= _("Downloads") %></a></li>
37           <li id="item-support"><a href="http://en.opensuse.org/Sitemap#support"><%= _("Support") %></a></li>
38           <li id="item-community"><a href="http://en.opensuse.org/Sitemap#community"><%= _("Community") %></a></li>
39           <li id="item-development"><a href="http://en.opensuse.org/Sitemap#development"><%= _("Development") %></a></li>
40         </ul>
41       </div>
42     </div>
43
44     <% unless flash.empty? %>
45       <div id="flash-messages" class="container_16" >
46         <% if flash[:success] or flash[:note] %>
47           <div class="grid_16 alpha omega">
48             <div class="ui-state-highlight ui-corner-all">
49               <p>
50                 <span class="ui-icon ui-icon-info"/>
51                 <%=h flash[:success] %><%=h flash[:note] %>
52               </p>
53             </div>
54           </div>
55         <% end %>
56
57         <% if flash[:warn] or flash[:error] %>
58           <div class="grid_16 alpha omega">
59             <div class="ui-state-error ui-corner-all">
60               <p>
61                 <span class="ui-icon ui-icon-alert" />
62                 <%=h flash[:warn] %><%=h flash[:error] %>
63               </p>
64             </div>
65           </div>
66         <% end %>
67       </div>
68     <% end %>
69
70     <div id="content" class="container_12 content-wrapper">
71       <div class="grid_9 alpha">
72         
73       <%= render :partial => 'search/search_box' %>
74
75         <div class="box box-shadow">
76           <h2 class="box-header">
77             <span class="alignleft"><%= @page_title -%></span>
78             <% if @right_box == :search -%>
79               <span class="alignright" style="padding-right: 10px">
80                 <% if @release != "developer" -%>
81                   <%= _('switch to') -%> <%= link_to _('Development Version'), {:controller => "main", :action => "developer", :lang => @lang } -%>
82                 <% else -%>
83                   <%= _('switch to') -%> <%= link_to _('Released Version'), {:controller => "main", :action => "index", :lang => @lang } -%>
84                 <% end -%>
85               </span>
86             <% end -%>
87           </h2>
88           <div>
89             <%= @content_for_layout %>
90           </div>
91         </div>
92
93       </div>
94       <div class="grid_3 omega">
95
96         <div class="box box-shadow grid_3 omega">
97           <h2 class="box-header centered"><%= _("Popular Software") %></h2>
98
99           <p>
100             <% top = top_downloads
101               top1=top[0][:count]
102               top10=top[-1][:count]
103               top.each do |query| -%>
104                 <% queryclass=((Float(query[:count] - top10) / (top1 - top10)) * 5).round %>
105               <a class='<%= "nowrap query query_#{queryclass}"%>'><%= query[:query] %></a>
106             <% end -%>
107           </p>
108         </div>
109
110         <div class="box box-shadow grid_3 omega">
111           <h2 class="box-header centered"><%=_("Getting Help")%></h2>
112           <ul class="navlist">
113             <li><a href="http://en.opensuse.org/Download_Help"><%=_("Download Help")%></a></li>
114             <li><a href="http://en.opensuse.org/Download_Help#Burn_the_ISO_Image.28s.29"><%=_("Burn CD/DVD Image(s)")%></a></li>
115             <li><a href="http://en.opensuse.org/Installation"><%=_("Installation Guides")%></a></li>
116             <li><a href="http://www.novell.com/documentation/opensuse112/"><%=_("Official Manuals")%></a></li>
117             <li><a href="http://en.opensuse.org/Additional_YaST_Package_Repositories"><%=_("Package Repositories")%></a></li>
118           </ul>
119         </div>
120
121         <div class="box box-shadow grid_3 omega">
122           <h2 class="box-header centered"><%=_("Sponsored by")%></h2>
123           <!--<p class="centered" style="color: #ccc; font-size: 0.8em"><%=_("Platinum Sponsor")%></p>-->
124           <p class="centered "style="color: #ccc; font-size: 0.8em;"><%=_("Gold Sponsor")%></p>
125           <p class="centered">
126             <a href="http://en.opensuse.org/Sponsors"><img title="<%=_("Sponsored by AMD")%>" alt="<%=_("Sponsored by AMD")%>" src="http://static.opensuse.org/c/images/common/Amd.png"/></a>
127             <a href="http://en.opensuse.org/Sponsors"><img title="<%=_("Sponsored by: IP Exchange")%>" alt="<%=_("Sponsored by: IP Exchange")%>" src="http://static.opensuse.org/c/images/common/Ip-exchange.gif"/></a>
128           </p>
129           <p class="centered "style="color: #ccc; font-size: 0.8em;"><%=_("Silver Sponsor")%></p>
130           <p class="centered">
131             <a href="http://en.opensuse.org/Sponsors"><img title="<%=_("Sponsored by: B1 Systems")%>" alt="<%=_("Sponsored by: B1 Systems")%>" src="http://static.opensuse.org/c/images/common/B1-systems-1.jpg"/></a>
132           </p>
133           <!--<p class="centered" style="color: #ccc; font-size: 0.8em"><%=_("Bronze Sponsor")%></p>-->
134         </div>
135
136         <div class="box box-shadow grid_3 omega">
137           <h2 class="box-header"><%=_("Buy openSUSE")%></h2>
138           <div class="centered" style="padding-left: 16px;">
139             <a href="<%= _("http://en.opensuse.org/Buy_openSUSE") %>"><img src="http://static.opensuse.org/c/images/common/openSUSE11.2_Box.jpg" title="<%=_("Buy openSUSE 11.2")%>" alt="<%=_("Buy openSUSE 11.2")%>"/></a>
140           </div>
141           <p class="centered">
142             <a href="<%= _("http://en.opensuse.org/Buy_openSUSE") %>" title="Buy openSUSE" style="text-decoration: none; font-weight: bold"><%=_("Buy openSUSE 11.2!")%></a>
143           </p>
144         </div>
145
146       </div>
147
148     </div>
149
150     <div id="footer" class="container_12">
151       <div id="footer-content" class="grid_12">
152       </div>
153       <div id="footer-legal" class="border-top grid_12">
154         <a href="http://en.opensuse.org/openSUSE:About">About openSUSE</a> |
155         <a href="http://en.opensuse.org/openSUSE:General_disclaimer">Legal information</a> |
156         <a href="mailto:webmaster@opensuse.org">Feedback</a>
157         <br/><br/>
158         <a href="http://www.novell.com/linux/"><img src="http://static.opensuse.org/c/images/common/founded_novell.gif" alt="Founded by Novell" /></a>
159       </div>
160     </div>
161
162     <% if @right_box == :search -%>
163       <!--[if lte IE 7]>
164           <script type="text/javascript">
165            alert("Please note that the Internet Explorer (all versions) is not capable of handling\nfiles larger than 4 GB.\n\nThis means that you will not be able to download the DVD images using IE.\n\nPlease use a different browser or a downloadmanager.")
166           </script>
167         <![endif]-->
168       <% end -%>
169
170   </body>
171 </html>