refinerycms 0.9.7.10 → 0.9.7.11

Sign up to get free protection for your applications and to get access to all the features.
Files changed (57) hide show
  1. data/Gemfile +9 -9
  2. data/bin/refinery-upgrade-096-to-097 +1 -1
  3. data/changelog.md +180 -158
  4. data/features/refinery/create_inquiries.feature +5 -7
  5. data/features/refinery/dashboard.feature +28 -16
  6. data/features/refinery/manage_files.feature +14 -19
  7. data/features/refinery/manage_images.feature +13 -26
  8. data/features/refinery/manage_inquiries.feature +6 -8
  9. data/features/refinery/manage_pages.feature +6 -0
  10. data/features/refinery/manage_users.feature +26 -0
  11. data/features/refinery/search.feature +37 -0
  12. data/features/refinery/site_bar.feature +1 -1
  13. data/features/step_definitions/refinery/file_steps.rb +4 -0
  14. data/features/step_definitions/refinery/image_steps.rb +4 -0
  15. data/features/step_definitions/refinery/inquiry_steps.rb +12 -0
  16. data/features/step_definitions/refinery/page_steps.rb +6 -2
  17. data/features/support/paths.rb +9 -0
  18. data/public/images/refinery/carousel-left.png +0 -0
  19. data/public/images/refinery/carousel-right.png +0 -0
  20. data/public/javascripts/jquery/jquery.jcarousel.js +896 -0
  21. data/public/javascripts/refinery/admin.js +50 -17
  22. data/public/javascripts/wymeditor/lang/da.js +47 -0
  23. data/public/stylesheets/refinery/refinery.css +20 -1
  24. data/vendor/plugins/images/app/controllers/admin/images_controller.rb +8 -8
  25. data/vendor/plugins/images/app/views/admin/images/_existing_image.html.erb +1 -1
  26. data/vendor/plugins/images/app/views/admin/images/_grid_view.html.erb +2 -1
  27. data/vendor/plugins/images/app/views/admin/images/_list_view_image.html.erb +2 -1
  28. data/vendor/plugins/images/app/views/admin/images/insert.html.erb +1 -1
  29. data/vendor/plugins/inquiries/app/controllers/admin/inquiries_controller.rb +2 -6
  30. data/vendor/plugins/inquiries/app/views/admin/inquiries/_inquiry.html.erb +2 -1
  31. data/vendor/plugins/inquiries/app/views/admin/inquiries/show.html.erb +2 -1
  32. data/vendor/plugins/inquiries/config/locales/pt-BR.yml +2 -0
  33. data/vendor/plugins/pages/app/views/admin/pages/_form_new_page_parts.html.erb +2 -2
  34. data/vendor/plugins/pages/app/views/admin/pages/_form_page_parts.html.erb +3 -3
  35. data/vendor/plugins/pages/app/views/admin/pages/_page.html.erb +1 -0
  36. data/vendor/plugins/pages/app/views/admin/pages/_sortable_list.html.erb +3 -1
  37. data/vendor/plugins/pages/app/views/admin/pages/index.html.erb +2 -6
  38. data/vendor/plugins/pages/config/locales/en.yml +2 -0
  39. data/vendor/plugins/pages/config/locales/pt-BR.yml +2 -0
  40. data/vendor/plugins/refinery/app/views/admin/_head.html.erb +6 -4
  41. data/vendor/plugins/refinery/app/views/shared/_head.html.erb +4 -3
  42. data/vendor/plugins/refinery/app/views/shared/_html5_for_ie.js.erb +5 -0
  43. data/vendor/plugins/refinery/app/views/shared/admin/_form_actions.html.erb +4 -1
  44. data/vendor/plugins/refinery/app/views/shared/admin/_search.html.erb +1 -1
  45. data/vendor/plugins/refinery/app/views/shared/admin/_sortable_list.html.erb +4 -4
  46. data/vendor/plugins/refinery/lib/crud.rb +62 -29
  47. data/vendor/plugins/refinery/lib/generators/refinery_plugin/templates/rails/init.rb +1 -1
  48. data/vendor/plugins/refinery/lib/generators/refinery_plugin/templates/views/admin/_sortable_list.html.erb +3 -1
  49. data/vendor/plugins/refinery/lib/generators/refinery_plugin/templates/views/admin/index.html.erb +1 -3
  50. data/vendor/plugins/refinery/lib/refinery.rb +1 -1
  51. data/vendor/plugins/refinery/lib/tasks/refinery.rake +5 -0
  52. data/vendor/plugins/refinery/plugins.md +1 -1
  53. data/vendor/plugins/refinery_dialogs/app/views/layouts/admin_dialog.html.erb +1 -0
  54. data/vendor/plugins/resources/app/controllers/admin/resources_controller.rb +2 -5
  55. data/vendor/plugins/resources/app/views/admin/resources/_resource.html.erb +2 -1
  56. metadata +15 -5
  57. data/app/controllers/application.rb +0 -3
@@ -32,9 +32,6 @@ init_interface = function() {
32
32
  // make sure that users can tab to wymeditor fields and add an overlay while loading.
33
33
  $('textarea.wymeditor').each(function() {
34
34
  textarea = $(this);
35
- /*overlay = $("<div class='wym_loading_overlay'>&nbsp;</div>")
36
- .css({'height': textarea.height(), 'width': textarea.width()});
37
- textarea.before(overlay);*/
38
35
  if ((instance = WYMeditor.INSTANCES[$((textarea.next('.wym_box').find('iframe').attr('id')||'').split('_')).last().get(0)]) != null) {
39
36
  if ((next = textarea.parent().next()) != null && next.length > 0) {
40
37
  next.find('input, textarea').keydown($.proxy(function(e) {
@@ -62,9 +59,21 @@ init_interface = function() {
62
59
  $('form input[type=text]:first').focus();
63
60
 
64
61
  // ensure that the menu isn't wider than the page_container or else it looks silly to round that corner.
65
- var last_item_offset = (last_item = $('#menu a:visible:last')).offset();
66
- if (last_item_offset && ((last_item_offset.left + last_item.outerWidth() - $('#menu').offset().left + 5) < $('#page_container').outerWidth())) {
67
- $("#page_container:not('.login #page_container')").corner('5px tr');
62
+ if (($menu = $('#menu')).length > 0) {
63
+ $menu.jcarousel({
64
+ vertical: false
65
+ , scroll: 1
66
+ , buttonNextHTML: "<img src='/images/refinery/carousel-right.png' alt='down' height='15' width='10' />"
67
+ , buttonPrevHTML: "<img src='/images/refinery/carousel-left.png' alt='up' height='15' width='10' />"
68
+ , listTag: $menu.get(0).tagName.toLowerCase()
69
+ , itemTag: $menu.children(':first').get(0).tagName.toLowerCase()
70
+ });
71
+
72
+ if ($menu.outerWidth() < $('#page_container').outerWidth()) {
73
+ $("#page_container:not('.login #page_container')").corner('5px tr');
74
+ } else {
75
+ $("#page_container:not('.login #page_container')").uncorner();
76
+ }
68
77
  }
69
78
 
70
79
  $('#current_locale li a').click(function(e) {
@@ -107,8 +116,8 @@ init_flash_messages = function(){
107
116
  init_modal_dialogs = function(){
108
117
  $('a[href*="dialog=true"]').not('#dialog_container a').each(function(i, anchor) {
109
118
  $(anchor).data({
110
- 'dialog-width': parseInt($(anchor.href.match("width=([0-9]*)")).last().get(0), 928)||928
111
- , 'dialog-height': parseInt($(anchor.href.match("height=([0-9]*)")).last().get(0), 473)||473
119
+ 'dialog-width': parseInt($($(anchor).attr('href').match("width=([0-9]*)")).last().get(0))||928
120
+ , 'dialog-height': parseInt($($(anchor).attr('href').match("height=([0-9]*)")).last().get(0))||473
112
121
  , 'dialog-title': ($(anchor).attr('title') || $(anchor).attr('name') || $(anchor).html() || null)
113
122
  }).attr('href', $(anchor).attr('href').replace(/(\&(amp\;)?)?dialog\=true/, '')
114
123
  .replace(/(\&(amp\;)?)?width\=\d+/, '')
@@ -257,8 +266,9 @@ init_tooltips = function(args){
257
266
  tooltip.css({
258
267
  'opacity': 0
259
268
  , 'maxWidth': '300px'
260
- , 'left': ((left = $(this).offset().left - (tooltip.outerWidth() / 2) + ($(this).outerWidth() / 2)) >= 0 ? left : 0)
261
269
  });
270
+ required_left_offset = $(this).offset().left - (tooltip.outerWidth() / 2) + ($(this).outerWidth() / 2);
271
+ tooltip.css('left', (required_left_offset > 0 ? required_left_offset : 0));
262
272
 
263
273
  var tooltip_offset = tooltip.offset();
264
274
  var tooltip_outer_width = tooltip.outerWidth();
@@ -276,7 +286,7 @@ init_tooltips = function(args){
276
286
 
277
287
  if (tooltip_offset = tooltip.offset()) {
278
288
  nib.css({
279
- 'left': tooltip_offset.left + (tooltip_outer_width / 2) - 5
289
+ 'left': $(this).offset().left + ($(this).outerWidth() / 2) - 5
280
290
  , 'top': tooltip_offset.top + tooltip.height()
281
291
  });
282
292
  }
@@ -298,18 +308,26 @@ init_tooltips = function(args){
298
308
 
299
309
  }, function(e) {
300
310
  $(this).stopTime('tooltip');
301
- (tooltip = $('.tooltip')).css('z-index', '-1').animate({
302
- top: tooltip.offset().top - 20
311
+ if ((tt_offset = (tooltip = $('.tooltip')).css('z-index', '-1').offset()) == null) {
312
+ tt_offset = {'top':0,'left':0};
313
+ }
314
+ tooltip.animate({
315
+ top: tt_offset.top - 20
303
316
  , opacity: 0
304
317
  }, 125, 'swing', function(){
305
318
  $(this).remove();
306
319
  });
307
- (nib = $('.tooltip-nib')).animate({
308
- top: nib.offset().top - 20
320
+ if ((nib_offset = (nib = $('.tooltip-nib')).offset()) == null) {
321
+ nib_offset = {'top':0,'left':0};
322
+ }
323
+ nib.animate({
324
+ top: nib_offset.top - 20
309
325
  , opacity: 0
310
326
  }, 125, 'swing', function(){
311
327
  $(this).remove();
312
- })
328
+ });
329
+ }).click(function(e) {
330
+ $(this).stopTime('tooltip');
313
331
  });
314
332
  if ($(element).attr('tooltip') == null) {
315
333
  $(element).attr('tooltip', $(element).attr('title'));
@@ -823,9 +841,24 @@ var list_reorder = {
823
841
  serialized += "&continue_reordering=false";
824
842
 
825
843
  $.post(list_reorder.update_url, serialized, function(data) {
826
- $(list_reorder.sortable_list).html(data);
844
+ // handle the case where we get the whole list back including the <ul> or whatever.
845
+ if (data.match(new RegExp("^"+ $(list_reorder.sortable_list).get(0).tagName.toLowerCase() + "\ id=\"|\'" + list_reorder.sortable_list + "\"|\'>")).length == 1) {
846
+ // replace reorder authenticity token's value.
847
+ $('#reorder_authenticity_token').val($($(data.split('reorder_authenticity_token')).last().get(0).split('value=\'')).last().get(0).split('\'')[0]);
848
+ // replace actual list content.
849
+ $(list_reorder.sortable_list).html($(data).html());
850
+ } else {
851
+ $(list_reorder.sortable_list).html(data);
852
+ }
827
853
 
828
- list_reorder.restore_controls(e);
854
+ // if we get passed a script tag, re-enable reordering.
855
+ matches = data.replace('"', "'")
856
+ .match(/<script\ type='text\/javascript'>([^<]*)<\/script>/im);
857
+ if (matches != null && matches.length > 1) {
858
+ list_reorder.enable_reordering();
859
+ } else {
860
+ list_reorder.restore_controls(e);
861
+ }
829
862
  });
830
863
  } else {
831
864
  list_reorder.restore_controls(e);
@@ -0,0 +1,47 @@
1
+ WYMeditor.STRINGS['da'] = {
2
+ Strong: 'Kraftig',
3
+ Bold: 'Fed',
4
+ Emphasis: 'Fremhævet',
5
+ Superscript: 'Superscript',
6
+ Subscript: 'Subscript',
7
+ Ordered_List: 'Sorteret liste',
8
+ Unordered_List: 'Punktopstillet liste',
9
+ Indent: 'Ryk ind',
10
+ Outdent: 'Ryk ud',
11
+ Undo: 'Fortryd',
12
+ Redo: 'Igen',
13
+ Link: 'Tilføj link',
14
+ Unlink: 'Fjern link',
15
+ Image: 'Indsæt billede',
16
+ Table: 'Indsæt tabel',
17
+ HTML: 'HTML',
18
+ Paragraph: 'Afsnit',
19
+ Heading_1: 'Overskrift 1',
20
+ Heading_2: 'Overskrift 2',
21
+ Heading_3: 'Overskrift 3',
22
+ Heading_4: 'Overskrift 4',
23
+ Heading_5: 'Overskrift 5',
24
+ Heading_6: 'Overskrift 6',
25
+ Preformatted: 'Præformattet',
26
+ Blockquote: 'Blockquote',
27
+ Table_Header: 'Tabel overskrift',
28
+ URL: 'URL',
29
+ Title: 'Titel',
30
+ Alternative_Text: 'Alternativ tekst',
31
+ Caption: 'Overskrift',
32
+ Summary: 'Resume',
33
+ Number_Of_Rows: 'Antal rækker',
34
+ Number_Of_Cols: 'Antal kolonner',
35
+ Insert: 'Indsæt',
36
+ Submit: 'Gem',
37
+ Cancel: 'Annullér',
38
+ Choose: 'Vælg',
39
+ Preview: 'Vis',
40
+ Paste_From_Word: 'Indsæt tekst her under',
41
+ Tools: 'Værktøjer',
42
+ Containers: 'Containere',
43
+ Classes: 'Klasser',
44
+ Status: 'Status',
45
+ Source_Code: 'Kilde kode',
46
+ Css_Class: 'Tilføj CSS klasse'
47
+ };
@@ -295,7 +295,7 @@ body.login #header_content h1 {
295
295
  padding-bottom: 0px;
296
296
  line-height: 60px;
297
297
  }
298
- #menu {
298
+ #menu, #header_content .jcarousel-container {
299
299
  display: block;
300
300
  margin: 0px;
301
301
  padding: 0px;
@@ -305,6 +305,25 @@ body.login #header_content h1 {
305
305
  right: 0px;
306
306
  background: transparent;
307
307
  }
308
+ #header_content .jcarousel-container {
309
+ position: absolute !important;
310
+ }
311
+ #header_content .jcarousel-container .jcarousel-prev,
312
+ #header_content .jcarousel-container .jcarousel-next {
313
+ position: absolute;
314
+ top: 13px;
315
+ cursor: pointer;
316
+ }
317
+ #header_content .jcarousel-container .jcarousel-prev {
318
+ left: -20px;
319
+ }
320
+ #header_content .jcarousel-container .jcarousel-next {
321
+ right: -20px;
322
+ }
323
+ #header_content .jcarousel-container .jcarousel-prev-disabled,
324
+ #header_content .jcarousel-container .jcarousel-next-disabled {
325
+ display: none !important;
326
+ }
308
327
  #menu.ui-sortable a {
309
328
  cursor: move;
310
329
  }
@@ -2,19 +2,19 @@ class Admin::ImagesController < Admin::BaseController
2
2
 
3
3
  include Admin::ImagesHelper
4
4
 
5
- crudify :image, :order => "created_at DESC", :conditions => "parent_id is NULL", :sortable => false
5
+ crudify :image,
6
+ :order => "created_at DESC",
7
+ :conditions => "parent_id is NULL",
8
+ :search_conditions => "parent_id IS NULL",
9
+ :sortable => false
10
+
6
11
  before_filter :change_list_mode_if_specified, :init_dialog
7
12
 
8
13
  def index
9
14
  if searching?
10
- @images = Image.paginate_search params[:search],
11
- :page => params[:page],
12
- :order => "created_at DESC",
13
- :conditions => "parent_id IS NULL"
15
+ search_and_paginate_all_images
14
16
  else
15
- @images = Image.paginate :page => params[:page],
16
- :order => "created_at DESC",
17
- :conditions => "parent_id IS NULL"
17
+ paginate_all_images
18
18
  end
19
19
 
20
20
  if RefinerySetting.find_or_set(:group_images_by_date_uploaded, true)
@@ -45,6 +45,6 @@
45
45
  :submit_button_text => t('.submit_insert'),
46
46
  :hide_cancel => false,
47
47
  :hide_delete => true,
48
- :cancel_title => ''
48
+ :cancel_title => nil
49
49
  } if @app_dialog or @images.any? %>
50
50
  </div>
@@ -11,7 +11,8 @@
11
11
  <%= link_to refinery_icon_tag('delete.png'), admin_image_path(image),
12
12
  :class => "cancel confirm-delete",
13
13
  :title => t('admin.images.image.delete.title'),
14
- :'data-confirm' => t('admin.images.image.delete.message', :title => image.filename) %>
14
+ :'data-confirm' => t('admin.images.image.delete.message', :title => image.filename),
15
+ :'data-method' => "delete" %>
15
16
  </span>
16
17
  </li>
17
18
  <% end -%>
@@ -12,7 +12,8 @@
12
12
  <%= link_to refinery_icon_tag('delete.png'), admin_image_path(list_view_image),
13
13
  :class => "cancel confirm-delete",
14
14
  :title => t('admin.images.image.delete.title'),
15
- :'data-confirm' => t('admin.images.image.delete.message', :title => list_view_image.filename) %>
15
+ :'data-confirm' => t('admin.images.image.delete.message', :title => list_view_image.filename),
16
+ :'data-method' => "delete" %>
16
17
  </span>
17
18
  </li>
18
19
  <% end %>
@@ -33,7 +33,7 @@
33
33
  :hide_delete => true,
34
34
  :hide_submit => true,
35
35
  :cancel_button_text => t('shared.admin.message.close'),
36
- :cancel_title => ''
36
+ :cancel_title => nil
37
37
  } %>
38
38
  <% end %>
39
39
  </div>
@@ -5,17 +5,13 @@ class Admin::InquiriesController < Admin::BaseController
5
5
  before_filter :get_spam_count, :only => [:index, :spam]
6
6
 
7
7
  def index
8
- if searching?
9
- @inquiries = Inquiry.ham.find_with_index params[:search]
10
- end
8
+ @inquiries = Inquiry.ham.with_query(params[:search]) if searching?
11
9
 
12
10
  @grouped_inquiries = group_by_date(Inquiry.ham)
13
11
  end
14
12
 
15
13
  def spam
16
- if searching?
17
- @inquiries = Inquiry.spam.find_with_index params[:search]
18
- end
14
+ @inquiries = Inquiry.spam.with_query(params[:search]) if searching?
19
15
 
20
16
  @grouped_inquiries = group_by_date(Inquiry.spam)
21
17
  end
@@ -7,7 +7,8 @@
7
7
  <%= link_to refinery_icon_tag('delete.png'), admin_inquiry_url(inquiry),
8
8
  :class => "cancel confirm-delete",
9
9
  :title => t('.title'),
10
- :'data-confirm' => t('.remove_inquiry', :name => inquiry.name) -%>
10
+ :'data-confirm' => t('.remove_inquiry', :name => inquiry.name),
11
+ :'data-method' => "delete" -%>
11
12
 
12
13
  <%= link_to refinery_icon_tag('zoom.png'), admin_inquiry_url(inquiry),
13
14
  :title => t('.read_inquiry') -%>
@@ -16,7 +16,8 @@
16
16
  <li>
17
17
  <%= link_to t('.title'), admin_inquiry_url(@inquiry), :class => 'delete_icon no-tooltip confirm-delete',
18
18
  :title => t('.title'),
19
- :'data-confirm' => t('admin.inquiries.inquiry.remove_inquiry', :name => @inquiry.name) %>
19
+ :'data-confirm' => t('admin.inquiries.inquiry.remove_inquiry', :name => @inquiry.name),
20
+ :'data-method' => "delete" %>
20
21
  </li>
21
22
  </ul>
22
23
  </div>
@@ -40,6 +40,8 @@ pt-BR:
40
40
  submenu:
41
41
  update_notified: Atualizar quem recebe a notificação
42
42
  edit_confirmation_email: Editar email de confirmação
43
+ inbox: Caixa de Entrada
44
+ spam: Spam
43
45
  index:
44
46
  search_results_for: Resultados da busca por {{query}}
45
47
  open_inquiries: Mensagens abertas
@@ -1,7 +1,7 @@
1
1
  <div id='new_page_part_dialog' style='display: none'>
2
2
  <div class='field'>
3
- <label for='new_page_part_title'>Title</label>
4
- <input id='new_page_part_title' value='' class='larger' size='40' />
3
+ <label for='new_page_part_title'><%= t('.title') %></label>
4
+ <input id='new_page_part_title' value='' class='larger widest' />
5
5
  <input id='new_page_part_index' type='hidden' value='<%= @page.parts.size %>' />
6
6
  </div>
7
7
  <%= render :partial => "/shared/admin/form_actions", :locals => {
@@ -3,13 +3,13 @@
3
3
  <li>
4
4
  <%= link_to refinery_icon_tag('add.png'), '#',
5
5
  :id => 'add_page_part',
6
- :title => 'Create Content Section' %>
6
+ :title => t('admin.pages.form_advanced_options.create_content_section') %>
7
7
  </li>
8
8
  <li>
9
9
  <%= link_to refinery_icon_tag('delete.png'), '#',
10
- :title => 'Delete content section',
10
+ :title => t('admin.pages.form_advanced_options.delete_content_section'),
11
11
  :class => 'delete_page_part',
12
- :name => 'Delete Content Section',
12
+ :name => t('admin.pages.form_advanced_options.delete_content_section'),
13
13
  :id => 'delete_page_part' %>
14
14
  </li>
15
15
  </ul>
@@ -20,6 +20,7 @@
20
20
  :title => t('.edit_this_page') %>
21
21
  <%= link_to refinery_icon_tag('delete.png'), admin_page_url(page),
22
22
  :class => "cancel confirm-delete",
23
+ :'data-method' => "delete",
23
24
  :title => t('.confirm_delete_page_title') if page.deletable? %>
24
25
  </span>
25
26
  </div>
@@ -1,2 +1,4 @@
1
- <%= render :partial => "page", :collection => @pages %>
1
+ <ul id='sortable_list'>
2
+ <%= render :partial => "page", :collection => @pages %>
3
+ </ul>
2
4
  <%= render :partial => "/shared/admin/sortable_list", :locals => {:continue_reordering => (defined?(continue_reordering) ? continue_reordering : true)} %>
@@ -18,17 +18,13 @@
18
18
  <% if searching? %>
19
19
  <h2><%= t('admin.search_results_for', :query => h(params[:search])) %></h2>
20
20
  <% if @pages.any? %>
21
- <ul id='sortable_list'>
22
- <%= render :partial => "sortable_list" %>
23
- </ul>
21
+ <%= render :partial => "sortable_list" %>
24
22
  <% else %>
25
23
  <p><%= t('admin.search_no_results') %></p>
26
24
  <% end %>
27
25
  <% else %>
28
26
  <% if @pages.any? %>
29
- <ul id='sortable_list'>
30
- <%= render :partial => "sortable_list" %>
31
- </ul>
27
+ <%= render :partial => "sortable_list" %>
32
28
  <% else %>
33
29
  <p>
34
30
  <strong><%=t('.no_pages_yet')%></strong>
@@ -37,6 +37,8 @@ en:
37
37
  confirm_delete_page_message: "Are you sure you want to delete the page '{{title}}'?"
38
38
  hidden: hidden
39
39
  draft: draft
40
+ form_new_page_parts:
41
+ title: Title
40
42
  form_advanced_options:
41
43
  toggle_advanced_options: Click to access meta tag settings and menu options
42
44
  parent_page: Parent page
@@ -55,6 +55,8 @@ pt-BR:
55
55
  confirm_delete_page_message: "Você tem certeza que quer deletar a página '{{title}}'?"
56
56
  hidden: oculta
57
57
  draft: rascunho
58
+ form_new_page_parts:
59
+ title: Título
58
60
  form_advanced_options:
59
61
  toggle_advanced_options: Clique aqui para acessar as configurações de meta tag e opções do menu
60
62
  create_content_section: Criar seção de conteúdo
@@ -5,10 +5,11 @@
5
5
  css_caching = js_caching && request.env['HTTP_USER_AGENT'] !~ /MSIE/
6
6
  -%>
7
7
  <head>
8
- <% if request.env['HTTP_USER_AGENT'] =~ /MSIE/%>
9
- <!--[if lt IE 9]>
10
- <%= javascript_include_tag('http://html5shiv.googlecode.com/svn/trunk/html5.js') %>
11
- <![endif]-->
8
+ <% # IE only html5 enabling script
9
+ if request.env['HTTP_USER_AGENT'] =~ /MSIE/%>
10
+ <script type='text/javascript'>
11
+ <%= render :partial => '/shared/html5_for_ie.js' %>
12
+ </script>
12
13
  <% end %>
13
14
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
14
15
  <title><%= RefinerySetting.find_or_set(:site_name, 'Company Name') %> - Refinery</title>
@@ -28,6 +29,7 @@
28
29
  'jquery/jquery.textTruncate.js',
29
30
  'jquery/jquery.html5-placeholder-shim.js',
30
31
  'jquery/jquery.timers.js',
32
+ 'jquery/jquery.jcarousel.js',
31
33
  :cache => (js_caching ? "cache/jquery-plugins" : false) %>
32
34
 
33
35
  <%= javascript_include_tag 'refinery/i18n' %>
@@ -2,15 +2,16 @@
2
2
  <head>
3
3
  <title><%= browser_title(yield(:title)) %></title>
4
4
  <%= render :partial => 'shared/google_analytics' unless local_request? %>
5
- <%= "<!--[if lt IE 9]>#{javascript_include_tag('http://html5shiv.googlecode.com/svn/trunk/html5.js')}<![endif]-->".html_safe if request.env['HTTP_USER_AGENT'] =~ /MSIE/ %>
5
+ <%= # IE only HTML5 enabling script:
6
+ "<script type='text/javascript'>#{render :partial => '/shared/html5_for_ie.js'}</script>" if request.env['HTTP_USER_AGENT'] =~ /MSIE/ %>
6
7
  <%= stylesheet_link_tag "application", "formatting", :theme => theme %>
7
8
  <%= stylesheet_link_tag "theme" %>
8
9
  <%= stylesheet_link_tag "home", :theme => theme if home_page? %>
9
10
  <%= "<!--[if IE 7]>#{stylesheet_link_tag 'ie7'}<![endif]-->" if request.env['HTTP_USER_AGENT'] =~ /MSIE/ -%>
10
11
  <link rel="shortcut icon" href="/favicon.ico" />
11
12
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
12
- <%= "<meta name=\"keywords\" content=\"#{@meta.meta_keywords}\" />" if @meta.meta_keywords.present? %>
13
- <%= "<meta name=\"description\" content=\"#{@meta.meta_description}\" />" if @meta.meta_description.present? -%>
13
+ <%= "<meta name=\"keywords\" content=\"#{h @meta.meta_keywords}\" />" if @meta.meta_keywords.present? %>
14
+ <%= "<meta name=\"description\" content=\"#{h @meta.meta_description}\" />" if @meta.meta_description.present? -%>
14
15
  <%= yield :head_libraries %>
15
16
  <%= yield :head %>
16
17
  </head>