application.rhtml
4.81 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title>
<%= @environment.name() %>
<%- if @category -%>
→ <%= @category.full_name -%>
<%- end -%>
</title>
<meta name="description" content="FIXME: Descriptions of Noosfero" />
<meta name="keywords" content="Noosfero, Community, Open Source" />
<%#
stylesheet_import is better then stylesheet_link_tag because the stylesheet
must be loaded before the page show.
%>
<%= stylesheet_import %w( common help menu button search blocks forms login-box ) %>
<%= import_blocks_stylesheets %>
<%=
# Load the controller's css file if it exists:
css = "controller_"+ @controller.controller_name() +".css"
stylesheet_link_tag( css ) if File.exists?( "public/stylesheets/"+css )
%>
<%# FIXME %>
<%= stylesheet_link_tag '/designs/templates/default/stylesheets/style.css' %>
<%= stylesheet_link_tag '/designs/icons/default/style.css' %>
<%= javascript_include_tag(:defaults) %>
<%= javascript_include_tag 'menu' %>
<%= javascript_include_tag 'auto-open-menu' %>
<%= include_lightbox_header %>
<%# cms stuff %>
<% if params[:controller] == 'cms' %>
<%= javascript_include_tag 'cms' %>
<% end %>
</head>
<body class='noosfero category<%= category_color %><%=
# Identify the current controller and action for the CSS:
" controller_"+ @controller.controller_name() +
" action_"+ @controller.controller_name() +"_"+ @controller.action_name()
%>' onload='noosfero_init();'>
<script type="text/javascript">
/* Adds a class to "msie" to the body element if a Microsoft browser is
* detected. This is needed to workaround several of their limitations.
*/
if ( navigator.appVersion.indexOf("MSIE") > -1 ) {
document.body.className += " msie msie" +
navigator.appVersion.replace(/^.*MSIE\s+([0-9]+).*$/, "$1");
}
</script>
<% unless flash[:notice].nil? %>
<div id='notice' onclick="Element.hide('notice');">
<%= flash[:notice] %>
<%= javascript_tag(visual_effect(:fade, "notice", :duration => 15)) %>
</div>
<% end %>
<div id='accessibility_menu'>
<a href='#content' id='link_go_content'><span><%= _('Go to content') %></span></a>
</div><!-- accessibility_menu -->
<div id='path_category'>
<% if @category -%>
<%= @category.full_name(" → ") %>
<% end -%>
<%= javascript_tag(visual_effect(:fade, "path_category", :duration => 10)) %>
</div>
<div id="wrap">
<div id="beta-tag"><span>BETA</span></div>
<div id='noosfero_bar' style='position: absolute;'>
<div id='navigation_bar'>
<%= render :file => 'shared/categories_menu' %>
</div><!-- id='navigation_bar' -->
<script type="text/javascript">
prepareMenu('navigation_bar', { timeout: 1000 });
</script>
<div id='user_box'>
<%= render :file => 'shared/user_menu' %>
<%=
lightbox_link_to '<span class="icon-menu-search"></span>'+ _('Search'),
{ :controller => 'search', :action => 'popup' }, :id => 'open_search'
%>
</div><!-- id='user_box' -->
</div><!-- id="noosfero_bar" -->
<div id='frame'><!-- Frame que envolve toda pagina de um usuario -->
<div id='header'>
<!-- Abaixo um cabeçalho especifico para a pagina de usuario. -->
</div><!-- id='header' -->
<div id='content'>
<div id='header_content'>
</div>
<% if @controller.send(:boxes_editor?) %>
<%= yield %>
<%= display_boxes_editor(@controller.boxes_holder) %>
<% else %>
<% if uses_design_blocks? %>
<%= display_boxes(@controller.boxes_holder, yield) %>
<% else %>
<%= yield %>
<% end %>
<% end %>
</div><!-- id="content" -->
<div id="footer_content"><!-- Rodape do onteudo -->
</div><!-- id="footer_content" -->
</div><!-- id="frame" -->
</div><!-- id="wrap" -->
<div id="footer">
<!-- <a name='footer'/></a> -->
<%= localist_menu %>
<%= footer %>
</div><!-- id="footer" -->
<div id="better-browser-promotion" style="display:none">
<h3><%=
_('Hey! Your web browser is really old!') +'</h3><p/>'+
_('This great website will be not so good on that.
Don\'t you want to use Firefox? That is a great web browser, free,
and made by people of all the world parts.')
%><p/>
<b id="bbp-getff"><a href="http://getfirefox.com" class="icon-firefox" target="getff"><%= _('Get Firefox Now!') %></a></b>
</div>
<%= javascript_include_tag 'better-browser-promotion' %>
</body>
</html>