From 6424e10be5a89f175a74c71c55660412a169b8b8 Mon Sep 17 00:00:00 2001 From: erdgeist Date: Tue, 23 Jun 2026 18:04:37 +0200 Subject: Update deployed state to what's currently running --- app/helpers/admin_helper.rb | 4 ++-- app/helpers/content_helper.rb | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'app/helpers') diff --git a/app/helpers/admin_helper.rb b/app/helpers/admin_helper.rb index 232862b8..389f6dcb 100644 --- a/app/helpers/admin_helper.rb +++ b/app/helpers/admin_helper.rb @@ -3,9 +3,9 @@ module AdminHelper def language_selector case I18n.locale when :de - link_to 'English (Aktiv: Deutsch)', url_for(:overwrite_params => {:locale => :en}) + link_to raw('English'), url_for(:overwrite_params => {:locale => :en}) when :en - link_to 'Deutsch (Active: English)', url_for(:overwrite_params => {:locale => :de}) + link_to raw('Deutsch'), url_for(:overwrite_params => {:locale => :de}) end end end diff --git a/app/helpers/content_helper.rb b/app/helpers/content_helper.rb index 7286976f..17364f8b 100644 --- a/app/helpers/content_helper.rb +++ b/app/helpers/content_helper.rb @@ -43,7 +43,7 @@ module ContentHelper # Returns the published_at attribute of a page if it is not nil, otherwise # it returns the auto-filled value of the created_at attribute def date_for_page page - page.published_at.to_s(:db) rescue page.created_at.to_s(:db) + I18n.l(page.published_at, :format => :ccc) rescue I18n.l(page.created_at, :format => :ccc) end def author_for_page page @@ -80,10 +80,10 @@ module ContentHelper begin if content =~ /]*)>/ tag = $~.to_s - matched_data = $1.scan(/\w+\=\"[a-zA-Z\s\/_\d,]*\"/) + matched_data = $1.scan(/\w+\=\"[a-zA-Z\s\/_\d,.=]*\"/) matched_data.each do |data| - splitted_data = data.split("=") + splitted_data = data.split("=", 2) options[splitted_data[0].to_sym] = splitted_data[1].gsub(/\"/, "") end -- cgit v1.3