Skip to content

Instantly share code, notes, and snippets.

@ryuone
Created May 24, 2011 22:44
Show Gist options
  • Save ryuone/989927 to your computer and use it in GitHub Desktop.
Save ryuone/989927 to your computer and use it in GitHub Desktop.
tDiaryのHTML5対応
diff --git a/tdiary.rb b/tdiary.rb
index dcdb458..edae6ac 100644
--- a/tdiary.rb
+++ b/tdiary.rb
@@ -1078,6 +1078,8 @@ module TDiary
end
@io = @conf.io_class.new( self )
+ @headerfile = "header.rhtml"
+ @footerfile = "footer.rhtml"
# load logger
load_logger
end
@@ -1127,7 +1129,7 @@ module TDiary
r = File::open( "#{cache_path}/#{cache_file( prefix )}" ) {|f| f.read } rescue nil
end
if r.nil?
- files = ["header.rhtml", @rhtml, "footer.rhtml"]
+ files = [@headerfile, @rhtml, @footerfile]
rhtml = files.collect {|file|
path = "#{PATH}/skel/#{prefix}#{file}"
begin
@@ -1403,6 +1405,7 @@ EOS
class TDiaryAdmin < TDiaryAuthorOnlyBase
def initialize( cgi, rhtml, conf )
super
+ load_plugins
begin
@date = Time::local( @cgi.params['year'][0].to_i, @cgi.params['month'][0].to_i, @cgi.params['day'][0].to_i )
rescue ArgumentError, NameError
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment