Skip to content

Commit

Permalink
* dot.htaccess: add some comments about ErrorDocument.
Browse files Browse the repository at this point in the history
	* 00default.rb: skip hidden diary in navi_user.


git-svn-id: https://tdiary.svn.sourceforge.net/svnroot/tdiary/trunk/core@962 7f22e88f-374d-0410-998f-c91420d97ba2
  • Loading branch information
tadatadashi committed Dec 16, 2002
1 parent 89fd2c7 commit 0578bf1
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 5 deletions.
4 changes: 4 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
2002.12.16 TADA Tadashi <sho@spc.gr.jp>
* dot.htaccess: add some comments about ErrorDocument.
* 00default.rb: skip hidden diary in navi_user.

2002.12.15 TADA Tadashi <sho@spc.gr.jp>
* 00default.rb, 00lang.en.rb: fix wrong title tag when NYEAR mode.

Expand Down
4 changes: 3 additions & 1 deletion dot.htaccess
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,10 @@ Options +ExecCGI
# if you run tDiary with symbolic link, use settings below.
#Options FollowSymLinks

# if make anchor style as 'YYYYMMDD.html', use settings below,
# if making anchor style as 'YYYYMMDD.html', use settings below,
# then change 'your_URL_of_index.rb' and use html_anchor.rb plugn.
# But this method makes error into error_log of apache. It is better
# method to use mod_rewrite.
#
#<Files ~ "^([0-9]{4}|[0-9]{6}|[0-9]{8}).html$">
# ErrorDocument 404 your_URL_of_index.rb
Expand Down
15 changes: 13 additions & 2 deletions plugin/00default.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#
# 00default.rb: default plugins
# $Revision: 1.22 $
# $Revision: 1.23 $
#

#
Expand Down Expand Up @@ -36,7 +36,18 @@ def navi_user

days.sort!
days.unshift(nil).push(nil)
prev_day, dymmy, next_day = days[days.index(today) - 1, 3]
prev_day = next_day = nil
days.index( today ).times do |i|
prev_day = days[days.index( today ) - i - 1]
break unless prev_day
break if @diaries[prev_day].visible?
end
days.index( today ).times do |i|
next_day = days[days.index( today ) + i + 1]
break unless next_day
break if @diaries[next_day].visible?
end

if prev_day
result << %Q[<span class="adminmenu"><a href="#{@index}#{anchor prev_day}">&laquo;#{navi_prev_diary Time::local(*prev_day.scan(/^(\d{4})(\d\d)(\d\d)$/)[0])}</a></span>\n]
else
Expand Down
4 changes: 2 additions & 2 deletions tdiary.rb
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
=begin
== NAME
tDiary: the "tsukkomi-able" web diary system.
tdiary.rb $Revision: 1.73 $
tdiary.rb $Revision: 1.74 $
Copyright (C) 2001-2002, TADA Tadashi <sho@spc.gr.jp>
=end

TDIARY_VERSION = '1.5.1.20021215'
TDIARY_VERSION = '1.5.1.20021216'

require 'cgi'
require 'nkf'
Expand Down

0 comments on commit 0578bf1

Please sign in to comment.