Browse Source

SSL test

development
Godwin 10 years ago
parent
commit
db621f244b
  1. 2
      Gemfile
  2. 118
      Gemfile.lock
  3. 68
      app/assets/javascripts/application.js.coffee
  4. 75
      app/assets/javascripts/translations.js
  5. 7
      app/assets/stylesheets/application.css.scss
  6. 159
      app/assets/stylesheets/sass/_layout.scss
  7. 18
      app/assets/stylesheets/sass/_typography.scss
  8. 6
      app/controllers/application_controller.rb
  9. 1
      app/controllers/pages_controller.rb
  10. 3
      app/views/conferences/show.html.haml
  11. 6
      app/views/layouts/application.html.haml
  12. 73
      app/views/pages/translation_list.js.haml
  13. 5
      app/views/pages/translations.html.haml
  14. 13
      app/views/shared/_footer.html.haml
  15. 7
      app/views/shared/_navbar.html.haml
  16. 1
      config/environments/development.rb
  17. 4
      config/environments/production.rb
  18. 22
      server.crt
  19. 19
      server.csr
  20. 27
      server.key
  21. 30
      server.orig.key

2
Gemfile

@ -26,6 +26,8 @@ gem 'acts_as_list'
gem 'geocoder'
gem 'forgery'
gem 'paper_trail'
gem 'font-awesome-rails'
gem 'wysiwyg-rails'
group :development, :test do
gem 'rspec'

118
Gemfile.lock

@ -45,8 +45,6 @@ GEM
arel (4.0.2)
awesome_print (1.2.0)
bcrypt (3.1.7-x86-mingw32)
bcrypt-ruby (3.1.5-x86-mingw32)
bcrypt (>= 3.1.3)
better_errors (1.1.0)
coderay (>= 1.0.0)
erubis (>= 2.6.6)
@ -60,7 +58,7 @@ GEM
net-sftp (>= 2.0.0)
net-ssh (>= 2.0.14)
net-ssh-gateway (>= 1.1.0)
capybara (2.2.1)
capybara (2.4.1)
mime-types (>= 1.16)
nokogiri (>= 1.3.3)
rack (>= 1.0.0)
@ -88,10 +86,10 @@ GEM
coffee-rails (4.0.1)
coffee-script (>= 2.2.0)
railties (>= 4.0.0, < 5.0)
coffee-script (2.2.0)
coffee-script (2.3.0)
coffee-script-source
execjs
coffee-script-source (1.7.0)
coffee-script-source (1.7.1)
compass (0.12.6)
chunky_png (~> 1.2)
fssm (>= 0.2.7)
@ -109,9 +107,9 @@ GEM
safe_yaml (~> 1.0.0)
debug_inspector (0.0.2)
diff-lcs (1.2.5)
docile (1.1.3)
docile (1.1.5)
erubis (2.7.0)
execjs (2.0.2)
execjs (2.2.1)
factory_girl (4.4.0)
activesupport (>= 3.0.0)
factory_girl_rails (4.4.1)
@ -120,20 +118,22 @@ GEM
faraday (0.9.0)
multipart-post (>= 1.2, < 3)
ffi (1.9.3-x86-mingw32)
font-awesome-rails (4.1.0.0)
railties (>= 3.2, < 5.0)
forgery (0.6.0)
formatador (0.2.4)
foundation-rails (5.2.2.0)
formatador (0.2.5)
foundation-rails (5.3.0.1)
railties (>= 3.1.0)
sass (>= 3.2.0)
fssm (0.2.10)
geocoder (1.2.1)
geocoder (1.2.2)
guard (2.6.1)
formatador (>= 0.2.4)
listen (~> 2.7)
lumberjack (~> 1.0)
pry (>= 0.9.12)
thor (>= 0.18.1)
guard-rspec (4.2.9)
guard-rspec (4.2.10)
guard (~> 2.1)
rspec (>= 2.14, < 4.0)
haml (4.0.5)
@ -146,37 +146,37 @@ GEM
highline (1.6.21)
hike (1.2.3)
httpauth (0.2.1)
i18n (0.6.9)
i18n (0.6.11)
image_optimizer (1.2.1)
jquery-rails (3.1.0)
jquery-rails (3.1.1)
railties (>= 3.0, < 5.0)
thor (>= 0.14, < 2.0)
jquery-ui-rails (4.2.1)
jquery-ui-rails (5.0.0)
railties (>= 3.2.16)
json (1.8.1)
jwt (0.1.13)
multi_json (>= 1.5)
launchy (2.4.2)
addressable (~> 2.3)
listen (2.7.5)
listen (2.7.9)
celluloid (>= 0.15.2)
rb-fsevent (>= 0.9.3)
rb-inotify (>= 0.9)
lumberjack (1.0.5)
lumberjack (1.0.9)
mail (2.5.4)
mime-types (~> 1.16)
treetop (~> 1.4.8)
meta_request (0.3.0)
callsite
rack-contrib
railties
meta_request (0.3.3)
callsite (~> 0.0, >= 0.0.11)
rack-contrib (~> 1.1)
railties (>= 3.0.0, < 5.0.0)
method_source (0.8.2)
mime-types (1.25.1)
mini_magick (3.7.0)
subexec (~> 0.2.1)
mini_portile (0.6.0)
minitest (4.7.5)
multi_json (1.10.0)
multi_json (1.10.1)
multipart-post (2.0.0)
nested_form (0.3.2)
net-scp (1.2.1)
@ -186,6 +186,7 @@ GEM
net-ssh (2.9.1)
net-ssh-gateway (1.2.0)
net-ssh (>= 2.6.5)
netrc (0.7.7)
nokogiri (1.6.2.1-x86-mingw32)
mini_portile (= 0.6.0)
oauth (0.4.7)
@ -195,18 +196,14 @@ GEM
jwt (~> 0.1.4)
multi_json (~> 1.0)
rack (~> 1.2)
paper_trail (3.0.2)
paper_trail (3.0.3)
activerecord (>= 3.0, < 5.0)
activesupport (>= 3.0, < 5.0)
pg (0.17.1-x86-mingw32)
polyglot (0.3.4)
pry (0.9.12.6)
coderay (~> 1.0)
method_source (~> 0.8)
slop (~> 3.4)
pry (0.9.12.6-x86-mingw32)
coderay (~> 1.0)
method_source (~> 0.8)
polyglot (0.3.5)
pry (0.10.0-x86-mingw32)
coderay (~> 1.1.0)
method_source (~> 0.8.1)
slop (~> 3.4)
win32console (~> 1.3)
rack (1.5.2)
@ -234,28 +231,34 @@ GEM
thor (>= 0.18.1, < 2.0)
rake (10.3.2)
rb-fsevent (0.9.4)
rb-inotify (0.9.4)
rb-inotify (0.9.5)
ffi (>= 0.5.0)
rest-client (1.6.7)
mime-types (>= 1.16)
rspec (2.14.1)
rspec-core (~> 2.14.0)
rspec-expectations (~> 2.14.0)
rspec-mocks (~> 2.14.0)
rspec-core (2.14.8)
rspec-expectations (2.14.5)
diff-lcs (>= 1.1.3, < 2.0)
rspec-mocks (2.14.6)
rspec-rails (2.14.2)
rest-client (1.7.1-x86-mingw32)
ffi (~> 1.9)
mime-types (>= 1.16, < 3.0)
netrc (~> 0.7)
rspec (3.0.0)
rspec-core (~> 3.0.0)
rspec-expectations (~> 3.0.0)
rspec-mocks (~> 3.0.0)
rspec-core (3.0.2)
rspec-support (~> 3.0.0)
rspec-expectations (3.0.2)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.0.0)
rspec-mocks (3.0.2)
rspec-support (~> 3.0.0)
rspec-rails (3.0.1)
actionpack (>= 3.0)
activemodel (>= 3.0)
activesupport (>= 3.0)
railties (>= 3.0)
rspec-core (~> 2.14.0)
rspec-expectations (~> 2.14.0)
rspec-mocks (~> 2.14.0)
rubyzip (1.1.3)
rvm-capistrano (1.5.2)
rspec-core (~> 3.0.0)
rspec-expectations (~> 3.0.0)
rspec-mocks (~> 3.0.0)
rspec-support (~> 3.0.0)
rspec-support (3.0.2)
rubyzip (1.1.6)
rvm-capistrano (1.5.3)
capistrano (~> 2.15.4)
safe_yaml (1.0.3)
sass (3.2.19)
@ -264,7 +267,7 @@ GEM
sass (~> 3.2.0)
sprockets (~> 2.8, <= 2.11.0)
sprockets-rails (~> 2.0)
selenium-webdriver (2.41.0)
selenium-webdriver (2.42.0)
childprocess (>= 0.5.0)
multi_json (~> 1.0)
rubyzip (~> 1.0)
@ -275,9 +278,9 @@ GEM
simplecov-html (~> 0.8.0)
simplecov-html (0.8.0)
slop (3.5.0)
sorcery (0.8.5)
bcrypt-ruby (>= 3.0)
oauth (~> 0.4.4)
sorcery (0.8.6)
bcrypt (~> 3.1)
oauth (~> 0.4, >= 0.4.4)
oauth2 (>= 0.8.0, < 1.0.0)
sprockets (2.11.0)
hike (~> 1.2)
@ -292,15 +295,15 @@ GEM
term-ansicolor (1.3.0)
tins (~> 1.0)
thor (0.19.1)
thread_safe (0.3.3)
thread_safe (0.3.4)
tilt (1.4.1)
timers (1.1.0)
tins (1.3.0)
treetop (1.4.15)
polyglot
polyglot (>= 0.3.1)
tzinfo (0.3.39)
uglifier (2.5.0)
tzinfo (0.3.40)
uglifier (2.5.1)
execjs (>= 0.3.0)
json (>= 1.8.0)
unicode_utils (1.4.0)
@ -310,6 +313,9 @@ GEM
crack (>= 0.3.2)
websocket (1.0.7)
win32console (1.3.2-x86-mingw32)
wysiwyg-rails (1.1.5)
font-awesome-rails (= 4.1.0.0)
railties (>= 3.2, < 5.0)
xpath (2.0.0)
nokogiri (~> 1.3)
@ -330,6 +336,7 @@ DEPENDENCIES
compass-rails (~> 1.1.3)
coveralls
factory_girl_rails
font-awesome-rails
forgery
foundation-rails
geocoder
@ -359,3 +366,4 @@ DEPENDENCIES
uglifier (>= 1.3.0)
wdm (>= 0.1.0)
webmock
wysiwyg-rails

68
app/assets/javascripts/application.js.coffee

@ -1,22 +1,9 @@
#= require jquery
#= require jquery_ujs
#= require jquery.ui.sortable
# = #require jquery.turbolinks
# = #require turbolinks
#= require foundation
# FRONT END
# JS HANDLEBARS TEMPLATES
# require handlebars.runtime
# require jquery_nested_form
#= require froala_editor.min.js
# I18n
'use strict'
try Typekit.load() catch
startSpinner = ->
$('#loading-spinner').show()
@ -170,6 +157,7 @@ $ ->
#head = document.getElementsByTagName("head")[0];
#head.appendChild(trial);
#$(document).foundation();
#$('[data-editable]').editable({blockTags: ["n", "p", "h2", "blockquote", "pre"], buttons: ["formatBlock", "bold", "italic", "underline", "insertOrderedList", "insertUnorderedList", "sep", "createLink", "insertImage", "insertVideo", "html", "undo", "redo"]})
$('.field.country-select select').change () ->
$country = $(this)
country = $country.val()
@ -201,29 +189,29 @@ $ ->
updateFormFieldForm()
updateFormFieldList()
$('ul.sortable').sortable
handle: '.drag-sort',
items: 'li',
update: (event, props) ->
$(this).children().each (index, child) ->
$(child).find('.sortable-position').val(index + 1)
url = $(this).data().url
if url
data = $(this).find('input, select, textarea').serialize()
$.post url, data#,
# (json) ->
# console.log json
#, 'json'
$('table#translations td.value').click () ->
$this = $(this)
if !$this.find('.translation-form').length
startTranslating($this)
if $('table#translations').length
$(document).click (event) ->
$target = $(event.target)
if $target.closest('table#translations').length < 1 && !$target.hasClass('auto-translate')
stopTranslating()
$('.auto-translate').click (event) ->
event.preventDefault()
$td = $(this).parent()
saveTranslation($td, null, true)
#$('ul.sortable').sortable
# handle: '.drag-sort',
# items: 'li',
# update: (event, props) ->
# $(this).children().each (index, child) ->
# $(child).find('.sortable-position').val(index + 1)
# url = $(this).data().url
# if url
# data = $(this).find('input, select, textarea').serialize()
# $.post url, data#,
# # (json) ->
# # console.log json
# #, 'json'
#$('table#translations td.value').click () ->
# $this = $(this)
# if !$this.find('.translation-form').length
# startTranslating($this)
#if $('table#translations').length
# $(document).click (event) ->
# $target = $(event.target)
# if $target.closest('table#translations').length < 1 && !$target.hasClass('auto-translate')
# stopTranslating()
# $('.auto-translate').click (event) ->
# event.preventDefault()
# $td = $(this).parent()
# saveTranslation($td, null, true)

75
app/assets/javascripts/translations.js

@ -0,0 +1,75 @@
$(function() {
$('table#translations td.value').click(function() {
var $this = $(this);
if(!$this.find('.translation-form').length) {
startTranslating($this);
}
});
if ($('table#translations').length) {
$(document).click(function(event) {
$target = $(event.target);
if ($target.closest('table#translations').length < 1 && !$target.hasClass('auto-translate')) {
stopTranslating();
}
});
$('.auto-translate').click(function(event) {
event.preventDefault();
$td = $(this).parent();
saveTranslation($td, null, true);
});
}
});
function saveTranslation($td, $move_to, auto_translate) {
var val = '';
var do_auto_translate = true;
if (typeof auto_translate == "undefined" || !auto_translate) {
val = $td.find('textarea').val();
do_auto_translate = false;
}
var key = $td.parent().data().key;
var params = {
translationkey: key,
translationvalue: val,
translationlang: window.location.href.replace(/^.*\/(\w+)\/$/, '$1')
};
if (do_auto_translate) {
params['auto_translate'] = true;
}
params['authenticity_token'] = $('table#translations').data().token;
$.post('/translate/', params, function(json) {
$td.html(json.translation);
if ($td.parent().hasClass('not-exists')) {
$td.parent().removeClass('not-exists');
$td.parent().addClass('exists');
}
$('.translation-form').remove();
if (typeof $move_to != "undefined" && $move_to) {
startTranslating($move_to);
}
});
}
function stopTranslating() {
$('.translation-form').remove();
}
function startTranslating($td) {
stopTranslating();
var value = $td.parent().hasClass('not-exists') ? '' : $td.html().trim();
var $tr = $td.parent();
var key = $tr.data().key;
$td.append('<div class="translation-form"><textarea>' + value + '</textarea><button class="small" data-key="' + key + '">Save</textarea>');
var $textarea = $td.find('textarea');
$textarea.select();
$td.find('.translation-form button').click(function() { saveTranslation($td); });
$textarea.keydown(function(event) {
if (event.keyCode == 9) {
event.preventDefault();
var $new_tr = event.shiftKey ? $tr.prev() : $tr.next();
saveTranslation($td, $new_tr.find('.value'));
} else if (event.keyCode == 27) {
stopTranslating();
}
});
}

7
app/assets/stylesheets/application.css.scss

@ -1,4 +1,8 @@
/*
*= require froala_editor.min.css
*/
/*
* This is a manifest file that'll be compiled into application.css, which will include all the files
* listed below.
*
@ -23,6 +27,7 @@
// Libraries
@import "compass";
@import "font-awesome";
@import "foundation_and_overrides";
// Local settings (also edit foundation_and_overrides.scss to modify global variables)
@ -30,5 +35,3 @@
@import "sass/layout";
@import "sass/typography";
@import "sass/base";
#mfPreviewBarShow, #mfPreviewBar { display: none; }

159
app/assets/stylesheets/sass/_layout.scss

@ -15,36 +15,71 @@ body {
#main-nav {
background-color: $white;
width: 100%;
display: table;
display: block;
font-size: 0.6667em;
font-size: 2.4vw;
overflow: hidden;
height: 3.1em;
p {
display: none;
}
.buttons {
display: block;
width: 87%;
height: 100%;
//overflow: hidden;
white-space: nowrap;
float: right;
}
.button {
width: 29%;
width: 33.3%;
height: 100%;
margin: 0;
clear: left;
float: left;
&:hover {
background-color: rgba($white, 0.75);
}
&.active {
&:after {
content: '';
width: 0;
height: 0;
display: block;
position: absolute;
border-style: solid;
border-width: 1em 1em 0 1em;
border-color: #a0c700 transparent transparent transparent;
left: 0;
right: 0;
margin: 0.15em auto 0;
top: 100%;
z-index: 1;
border-width: 3vw 5vw 0 5vw;
}
}
&.logo {
background-color: $white;
background-color: transparent;
width: 13%;
border: 0;
padding: 0;
vertical-align: top;
overflow: auto;
/*svg {
float: left;
width: 50%;
}*/
//overflow: hidden;
height: 100%;
float: left;
.logo {
width: auto;
height: 2.4em;
height: 2em;
fill: $primary-color;
position: absolute;
left: 0;
margin-top: 0.15em;
}
.logo-text {
@ -60,36 +95,56 @@ body {
}
@include breakpoint(medium) {
display: block;
min-height: 100%;
float: left;
width: 25%;
padding: 2.5%;
font-size: 1em;
min-height: 100vh;
height: 5em;
position: absolute;
z-index: 10;
//background-color: $white;
//background-color: rgba($white, 0.33);
background-color: transparent;
@include background-image(linear-gradient(left, $white 0%, rgba($white, 0) 50%));
.button, p {
.buttons {
display: block;
width: 70%;
height: auto;
//overflow: hidden;
white-space: normal;
font-size: 0.75em;
margin-top: 2.5%;
}
p {
font-size: 0.9em;
font-size: 1.25em;
font-size: 1.25vw;
line-height: 1.2em;
}
.button {
width: auto;
margin: 0 0 1.25rem;
height: auto;
//float: none;
//margin: 0 0 1.25rem;
margin: 1%;
width: 30%;
&.logo {
position: relative;
width: 100%;
margin-bottom: 2em;
//width: 100%;
//height: auto;
//margin-bottom: 2em;
//float: none;
width: 25%;
margin: 0;
height: 100%;
float: left;
padding: 0.25em;
.logo {
position: static;
float: left;
width: 51%;
height: 100%;
margin-right: 5%;
margin: 0 5% 0 0;
}
img.logo {
@ -99,10 +154,48 @@ body {
.logo-text {
display: block;
width: 44%;
height: 100%;
}
}
}
}
@include breakpoint(large) {
display: block;
position: static;
height: auto;
min-height: 100%;
float: left;
width: 25%;
padding: 2.5%;
font-size: 1em;
min-height: 100vh;
.button, p {
display: block;
}
.button {
width: 100%;
height: auto;
margin: 0 0 1.25em;
float: none;
&.logo {
width: 100%;
height: auto;
float: none;
}
}
.buttons {
display: block;
width: 100%;
font-size: 1em;
margin: 2em 0 0;
float: none;
}
}
}
main {
@ -122,7 +215,7 @@ main {
}
.conferences & {
background-color: lighten(desaturate($conference-color, 25), 50);
background-color: lighten(desaturate($conference-color, 25), 42.5);
min-height: 100vh;
}
@ -265,6 +358,7 @@ main {
min-height: 40em;
height: 100%;
height: 100vh;
padding-top: 7.5em;
.organizations-show &,
.conferences-show & {
@ -306,6 +400,21 @@ main {
.organizations-index &,
.conferences-index & {
height: 30vw;
h1 {
font-size: 6vw;
}
}
}
@include breakpoint(large) {
padding-top: 0;
.organizations-index &,
.conferences-index & {
height: 15vw;
h1 {
font-size: 3.75vw;
margin-top: 6vw;

18
app/assets/stylesheets/sass/_typography.scss

@ -532,3 +532,21 @@ input:-webkit-autofill {
svg {
height: 0%;
}
#footer {
color: $white;
padding: 2.5em 0;
font-size: 1.25em;
a {
margin: 0 1em;
}
a, a:visited {
color: $white;
}
a:hover {
color: rgba($white, 0.5);
}
}

6
app/controllers/application_controller.rb

@ -7,11 +7,15 @@ class ApplicationController < ActionController::Base
# Prevent CSRF attacks by raising an exception.
# For APIs, you may want to use :null_session instead.
protect_from_forgery with: :exception
if ENV['RAILS_ENV'] || 'production'
force_ssl only: :success
end
before_filter :capture_page_info
def capture_page_info
init_vars
init_vars
$page_info = {:path => request.env['PATH_INFO'], :controller => params['controller'], :action => params['action']}
end

1
app/controllers/pages_controller.rb

@ -1,6 +1,7 @@
include ApplicationHelper
class PagesController < ApplicationController
#skip_before_filter :verify_authenticity_token, only: [:translate]
def home
@conferences = Conference.all

3
app/views/conferences/show.html.haml

@ -4,4 +4,5 @@
= tabs!
%h2=('About '+@conference.title)
%p=@conference.info.html_safe
%div{data: {editable: true}}
%p=@conference.info.html_safe

6
app/views/layouts/application.html.haml

@ -4,6 +4,7 @@
%meta{ charset: 'utf-8' }
%meta{ name: 'viewport', content: 'width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0' }
%title= yield_or_default :title, controller.action_name.titlecase
%meta{ name: 'description', content: (yield_or_default :description, 'Bike!Bike! is an international annual gathering organized by and for community bicycle projects') }
= csrf_meta_tags
= yield :head
/ Le HTML5 shim, for IE6-8 support of HTML elements
@ -25,8 +26,9 @@
\==================================================
/ Placed at the top of the document 'cause of turbolinks
=# javascript_include_tag '//use.typekit.net/iqv7hcg.js'
= javascript_include_tag 'application'
= javascript_include_tag 'nested_form'
= javascript_include_tag '//ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js'
=# javascript_include_tag 'application'
=# javascript_include_tag 'nested_form'
%body{ class: (yield_or_default :page_style) }
:javascript

73
app/views/pages/translation_list.js.haml

@ -0,0 +1,73 @@
- content_for :dom_ready
$('table#translations td.value').click(function() {
var $this = $(this);
if(!$this.find('.translation-form').length()) {
startTranslating($this);
}
});
if ($('table#translations').length()) {
$(document).click(function(event) {
$target = $(event.target);
if ($target.closest('table#translations').length() < 1 && !$target.hasClass('auto-translate')) {
stopTranslating();
}
$('.auto-translate').click (function(event) {
event.preventDefault();
$td = $(this).parent();
saveTranslation($td, null, true);
});
}
- content_for :scripts
function saveTranslation($td, $move_to, auto_translate) {
var val = '';
var do_auto_translate = true;
if (typeof auto_translate == "undefined" || !auto_translate) {
val = $td.find('textarea').val();
do_auto_translate = false;
}
var key = $td.parent().data().key;
var params = {
translationkey: key,
translationvalue: val,
translationlang: window.location.href.replace(/^.*\/(\w+)\/$/, '$1')
};
if (do_auto_translate) {
params['auto_translate'] = true;
}
$.post('/translate/', params, function(json) {
$td.html(json.translation);
if ($td.parent().hasClass('not-exists')) {
$td.parent().removeClass('not-exists');
$td.parent().addClass('exists');
}
$('.translation-form').remove();
if (typeof $move_to != "undefined" && $move_to) {
startTranslating($move_to);
}
});
}
function stopTranslating() {
$('.translation-form').remove();
}
function startTranslating($td) {
stopTranslating();
var value = $td.parent().hasClass('not-exists') ? '' : $td.html().trim();
var $tr = $td.parent();
var key = $tr.data().key;
$td.append('<div class="translation-form"><textarea>' + value + '</textarea><button class="small" data-key="' + key + '">Save</textarea>');
var $textarea = $td.find('textarea');
$textarea.select();
$td.find('.translation-form button').click(function() { saveTranslation($td); });
$textarea.keydown(function(event) {
if (event.keyCode == 9) {
event.preventDefault();
var $new_tr = event.shiftKey ? $tr.prev() : $tr.next();
saveTranslation($td, $new_tr.find('.value'));
} else if (event.keyCode == 27) {
stopTranslating();
}
});
}

5
app/views/pages/translations.html.haml

@ -3,7 +3,7 @@
.row
%h1
= _ 'language_translations', vars: {:language => (_ ('languages.' + @lang))}
%table.columns#translations
%table.columns#translations{data: {token: form_authenticity_token}}
%thead
%tr
%th.key=_'translations.Key'
@ -41,3 +41,6 @@
= translation_hint ? (_ "languages.#{I18n.locale.to_s}") + " = \"#{translation_hint}\"" : 'Nil'
- unless current_translation
%a{:href => '#', :class => 'auto-translate button small'}='Auto'
-# content_for :footer_scripts
= javascript_include_tag 'translations'

13
app/views/shared/_footer.html.haml

@ -1,6 +1,15 @@
%footer
%footer.row
.columns.medium-8.medium-push-1.large-6.large-push-3.text-center
%a{href: '/conferences/'}='Conferences'
\/
%a{href: '/conferences/'}='Organizations'
\/
%a{href: '/conferences/'}='Zine'
.columns.medium-3.large-3.text-right
&copy;2014 Bike!Bike!
:javascript
#{yield :scripts}
$(function(){
#{yield :dom_ready}
});
});
= yield :footer_scripts

7
app/views/shared/_navbar.html.haml

@ -4,9 +4,10 @@
=# image_tag('logo-text.png', class: 'logo-text')
= icon('logo', {:class => 'logo'})
= icon('logo-text', {:class => 'logo-text'})
= link_to (_'Conferences'), :conferences, {:class => ['button', 'conference']}
= link_to (_'Organizations'), {:controller => :organizations}, {:class => ['button', 'organization']}
= link_to (_'Zine'), 'http://zinezine.bikebike.org', :class => ['button', 'article']
.buttons
= link_to (_'Conferences'), :conferences, {:class => ['button', 'conference']}
= link_to (_'Organizations'), {:controller => :organizations}, {:class => ['button', 'organization']}
= link_to (_'Zine'), 'http://zinezine.bikebike.org', :class => ['button', 'article']
- if is_this_the_front_page?
%p
Bike!Bike! is an international annual gathering organized by and for community bicycle projects. The conference is a space for participants from shops and related advocacy groups to converge in a different city each year over a 4 day period to have workshops and strengthen our social network.

1
config/environments/development.rb

@ -45,6 +45,7 @@ BikeBike::Application.configure do
}
config.action_mailer.raise_delivery_errors = true
config.action_mailer.perform_deliveries = true
#config.force_ssl = true
#config.action_mailer.default_charset = 'utf-8'
#Carmen.i18n_backend.locale_paths = ''

4
config/environments/production.rb

@ -24,7 +24,7 @@ BikeBike::Application.configure do
# Compress JavaScripts and CSS.
config.assets.js_compressor = :uglifier
# config.assets.css_compressor = :sass
config.assets.css_compressor = :sass
# Do not fallback to assets pipeline if a precompiled asset is missed.
#config.assets.compile = true
@ -40,7 +40,7 @@ BikeBike::Application.configure do
# config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect' # for nginx
# Force all access to the app over SSL, use Strict-Transport-Security, and use secure cookies.
# config.force_ssl = true
config.force_ssl = true
# Set to :debug to see everything in the log.
config.log_level = :info

22
server.crt

@ -0,0 +1,22 @@
-----BEGIN CERTIFICATE-----
MIIDmjCCAoICCQCABjRcroTvojANBgkqhkiG9w0BAQUFADCBjjELMAkGA1UEBhMC
Q0ExCzAJBgNVBAgTAkFCMRAwDgYDVQQHEwdDYWxnYXJ5MRMwEQYDVQQKFApCaWtl
IUJpa2UhMQwwCgYDVQQLEwNEZXYxFjAUBgNVBAMTDWxvY2FsaG9zdC5zc2wxJTAj
BgkqhkiG9w0BCQEWFmdvb2Rnb2R3aW5AaG90bWFpbC5jb20wHhcNMTQwNzEyMDEz
MDU2WhcNMTUwNzEyMDEzMDU2WjCBjjELMAkGA1UEBhMCQ0ExCzAJBgNVBAgTAkFC
MRAwDgYDVQQHEwdDYWxnYXJ5MRMwEQYDVQQKFApCaWtlIUJpa2UhMQwwCgYDVQQL
EwNEZXYxFjAUBgNVBAMTDWxvY2FsaG9zdC5zc2wxJTAjBgkqhkiG9w0BCQEWFmdv
b2Rnb2R3aW5AaG90bWFpbC5jb20wggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEK
AoIBAQDIgjCmK03nV4zGQRZXIqYGnSwOCHQ0x8J+SXIFqxyfWdL64AL0Nygj2Sa8
f5RCW/G2Nt2v9VFrbUWfz2ZgdXK2htGxfbyQfskx9C7v+NrTFB/p3SzkQUzzIKy1
+qtIB+/PDnQyUFIN3tExFx4RUW4T8vMAmqisQgBvuDg6b3OvqjIIzEanMD+W1tcA
J4kHjoCOlaOVQ0amcDOJbKuSrJeOCGvkyYO/8RU8oK83opHI6ZinGBxt382avf+D
4QApOLW7M1wcroab7RjPNkNejyKHp6xIrg9SZs4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