Soks 0.0.2 → 0.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (132) hide show
  1. data/README.txt +5 -4
  2. data/bin/soks-create-wiki.rb +153 -19
  3. data/contrib/easyprompt.rb +58 -0
  4. data/contrib/easyprompt_licence.txt +504 -0
  5. data/contrib/redcloth-2.0.11.rb +3 -1
  6. data/lib/authenticators.rb +18 -2
  7. data/lib/soks-helpers.rb +207 -157
  8. data/lib/soks-model.rb +131 -114
  9. data/lib/soks-servlet.rb +54 -35
  10. data/lib/soks-storage.rb +134 -0
  11. data/lib/soks-upgrade-0.0.2.rb +70 -0
  12. data/lib/soks-utils.rb +129 -19
  13. data/lib/soks-view.rb +136 -62
  14. data/lib/soks.rb +3 -1
  15. data/{template → templates/default}/attachment/logo.png +0 -0
  16. data/templates/default/attachment/logo.tiff +0 -0
  17. data/templates/default/attachment/newpage.js +41 -0
  18. data/templates/default/attachment/print_stylesheet.css +7 -0
  19. data/templates/default/attachment/rss.png +0 -0
  20. data/{template → templates/default}/attachment/stylesheet.css +44 -17
  21. data/templates/default/banned_titles.txt +31 -0
  22. data/templates/default/content/Bug%3A%20In%20a%20list%20of%20links%2C%20the%20last%20link%20is%20sometimes%20not%20linked.textile +10 -0
  23. data/templates/default/content/Bug%3A%20Symbols%20are%20not%20always%20correctly%20rendered%20in%20html.textile +3 -0
  24. data/templates/default/content/Bug%3A%20Uploads%20are%20not%20password%20protected.textile +3 -0
  25. data/templates/default/content/How%20to%20administrate%20this%20wiki.textile +62 -0
  26. data/templates/default/content/How%20to%20change%20the%20way%20this%20wiki%20looks.textile +30 -0
  27. data/templates/default/content/How%20to%20export%20a%20site%20from%20this%20wiki.textile +60 -0
  28. data/{template → templates/default}/content/How%20to%20hack%20soks.textile +3 -2
  29. data/{template → templates/default}/content/How%20to%20import%20a%20site%20from%20instiki.textile +1 -1
  30. data/templates/default/content/How%20to%20use%20this%20wiki.textile +27 -0
  31. data/templates/default/content/List%20of%20changes.textile +35 -0
  32. data/{template → templates/default}/content/Picture%20of%20a%20pair%20of%20soks.textile +0 -0
  33. data/{template → templates/default}/content/Soks%20Licence.textile +0 -0
  34. data/templates/default/content/home%20page.textile +17 -0
  35. data/templates/default/start.rb +94 -0
  36. data/templates/default/version.txt +1 -0
  37. data/{template → templates/default}/views/Page_content.rhtml +0 -0
  38. data/templates/default/views/Page_edit.rhtml +61 -0
  39. data/templates/default/views/Page_meta.rhtml +40 -0
  40. data/templates/default/views/Page_print.rhtml +6 -0
  41. data/templates/default/views/Page_revisions.rhtml +19 -0
  42. data/templates/default/views/Page_rss.rhtml +55 -0
  43. data/{template → templates/default}/views/Page_search_results.rhtml +1 -1
  44. data/templates/default/views/Page_view.rhtml +4 -0
  45. data/templates/default/views/UploadPage_edit.rhtml +38 -0
  46. data/templates/default/views/frame.rhtml +41 -0
  47. data/templates/default/views/messages.yaml +6 -0
  48. data/templates/instiki/attachment/header_backdrop.png +0 -0
  49. data/templates/instiki/attachment/instiki_style_sheet.css +199 -0
  50. data/templates/instiki/attachment/logo.tiff +0 -0
  51. data/templates/instiki/attachment/logotext.png +0 -0
  52. data/templates/instiki/attachment/newpage.js +41 -0
  53. data/templates/instiki/attachment/rss.png +0 -0
  54. data/templates/instiki/banned_titles.txt +31 -0
  55. data/templates/instiki/content/AutomaticSummary.textile +24 -0
  56. data/templates/instiki/content/How%20to%20export%20a%20site%20from%20this%20wiki.textile +60 -0
  57. data/templates/instiki/content/How%20to%20hack%20soks.textile +61 -0
  58. data/templates/instiki/content/How%20to%20import%20a%20site%20from%20instiki.textile +13 -0
  59. data/{template → templates/instiki}/content/Improving%20the%20style%20of%20this%20wiki.textile +2 -2
  60. data/templates/instiki/content/Known%20bugs.textile +8 -0
  61. data/templates/instiki/content/List%20of%20changes.textile +34 -0
  62. data/templates/instiki/content/Picture%20of%20a%20pair%20of%20soks.textile +1 -0
  63. data/templates/instiki/content/Pointers%20on%20adjusting%20the%20settings.textile +62 -0
  64. data/templates/instiki/content/Pointers%20on%20how%20to%20use%20this%20wiki.textile +27 -0
  65. data/templates/instiki/content/Recent%20Blog%20Entries.textile +3 -0
  66. data/templates/instiki/content/Recent%20Changes%20to%20This%20Site.textile +48 -0
  67. data/templates/instiki/content/Site%20Index.textile +16 -0
  68. data/templates/instiki/content/Soks%20Licence.textile +64 -0
  69. data/{template → templates/instiki}/content/home%20page.textile +9 -4
  70. data/templates/instiki/start.rb +85 -0
  71. data/templates/instiki/version.txt +1 -0
  72. data/templates/instiki/views/Page_content.rhtml +1 -0
  73. data/templates/instiki/views/Page_edit.rhtml +8 -0
  74. data/templates/instiki/views/Page_meta.rhtml +34 -0
  75. data/templates/instiki/views/Page_print.rhtml +6 -0
  76. data/templates/instiki/views/Page_revisions.rhtml +17 -0
  77. data/templates/instiki/views/Page_rss.rhtml +55 -0
  78. data/templates/instiki/views/Page_search_results.rhtml +18 -0
  79. data/templates/instiki/views/Page_view.rhtml +2 -0
  80. data/templates/instiki/views/UploadPage_edit.rhtml +16 -0
  81. data/templates/instiki/views/frame.rhtml +90 -0
  82. data/templates/instiki/views/messages.yaml +6 -0
  83. data/templates/rails/attachment/2colheader.css +77 -0
  84. data/templates/rails/attachment/basics.css +98 -0
  85. data/templates/rails/attachment/header_backdrop.png +0 -0
  86. data/templates/rails/attachment/logo.tiff +0 -0
  87. data/templates/rails/attachment/logotext.png +0 -0
  88. data/templates/rails/attachment/newpage.js +41 -0
  89. data/templates/rails/attachment/rss.png +0 -0
  90. data/templates/rails/banned_titles.txt +31 -0
  91. data/templates/rails/content/AutomaticSummary.textile +24 -0
  92. data/templates/rails/content/How%20to%20export%20a%20site%20from%20this%20wiki.textile +60 -0
  93. data/templates/rails/content/How%20to%20hack%20soks.textile +61 -0
  94. data/templates/rails/content/How%20to%20import%20a%20site%20from%20instiki.textile +13 -0
  95. data/templates/rails/content/Improving%20the%20style%20of%20this%20wiki.textile +30 -0
  96. data/templates/rails/content/Known%20bugs.textile +8 -0
  97. data/templates/rails/content/List%20of%20changes.textile +34 -0
  98. data/templates/rails/content/Picture%20of%20a%20pair%20of%20soks.textile +1 -0
  99. data/templates/rails/content/Pointers%20on%20adjusting%20the%20settings.textile +62 -0
  100. data/templates/rails/content/Pointers%20on%20how%20to%20use%20this%20wiki.textile +27 -0
  101. data/templates/rails/content/Recent%20Blog%20Entries.textile +3 -0
  102. data/templates/rails/content/Recent%20Changes%20to%20This%20Site.textile +48 -0
  103. data/templates/rails/content/Site%20Index.textile +16 -0
  104. data/templates/rails/content/Soks%20Licence.textile +64 -0
  105. data/templates/rails/content/home%20page.textile +23 -0
  106. data/templates/rails/start.rb +85 -0
  107. data/templates/rails/version.txt +1 -0
  108. data/templates/rails/views/Page_content.rhtml +1 -0
  109. data/templates/rails/views/Page_edit.rhtml +61 -0
  110. data/templates/rails/views/Page_meta.rhtml +38 -0
  111. data/templates/rails/views/Page_print.rhtml +6 -0
  112. data/templates/rails/views/Page_revisions.rhtml +19 -0
  113. data/templates/rails/views/Page_rss.rhtml +55 -0
  114. data/templates/rails/views/Page_search_results.rhtml +19 -0
  115. data/templates/rails/views/Page_view.rhtml +3 -0
  116. data/templates/rails/views/UploadPage_edit.rhtml +38 -0
  117. data/templates/rails/views/frame.rhtml +60 -0
  118. data/templates/rails/views/messages.yaml +6 -0
  119. metadata +122 -28
  120. data/template/content/How%20to%20export%20a%20site%20from%20this%20wiki.textile +0 -5
  121. data/template/content/Pointers%20on%20adjusting%20the%20settings.textile +0 -39
  122. data/template/content/Pointers%20on%20how%20to%20use%20this%20wiki.textile +0 -21
  123. data/template/content/Recent%20Changes%20to%20This%20Site.textile +0 -203
  124. data/template/start.rb +0 -74
  125. data/template/views/AttachmentPage_edit.rhtml +0 -36
  126. data/template/views/ImagePage_edit.rhtml +0 -36
  127. data/template/views/Page_edit.rhtml +0 -34
  128. data/template/views/Page_print.rhtml +0 -5
  129. data/template/views/Page_revisions.rhtml +0 -18
  130. data/template/views/Page_rss.rhtml +0 -34
  131. data/template/views/Page_view.rhtml +0 -3
  132. data/template/views/frame.rhtml +0 -34
@@ -0,0 +1,17 @@
1
+ h1. Welcome!
2
+
3
+ You have succesfully installed soks. Remember it is work in progress, and definitely not fully de-bugged. So don't trust your mission critical sites to it.
4
+
5
+ If you are upgrading from a previous version, you may wish to glance at the list of changes.
6
+
7
+ [[insert Instructions and Howtos]]
8
+
9
+ [[insert known bugs]]
10
+
11
+ h2. Feedback
12
+
13
+ * Please send me your feedback. tamc@rubyforge.com.
14
+ * Or submit a bug at http://rubyforge.org/projects/soks/.
15
+ * To keep track of developments, you may wish to subscribe to the mailing list at http://rubyforge.org/projects/soks to be notified of updates.
16
+
17
+ [[insert picture of a pair of soks]]
@@ -0,0 +1,94 @@
1
+ #!/usr/local/bin/ruby
2
+
3
+ # This file was created automatically on <%= Time.now %>
4
+ # Uncomment different sections to enable features of this wiki.
5
+
6
+ #Add the required libraries to the search path:
7
+ $:.push( "<%= settings[:soks_libraries].join('","') %>" )
8
+
9
+ require 'soks'
10
+
11
+ module StartSoks
12
+
13
+ =begin
14
+ # If you uncomment this, don't forget to uncomment the authenticators line in the CUSTOMSETTINGS hash below!
15
+ # You can choose what level of authentication to apply based on regular expressions matched
16
+ # against the page title. These regexps are tried in order.Defaults are here:
17
+ authenticators = [ [ %r{/(view|rss|print|find|meta)/.*}, WEBrick::HTTPAuth::NoAuthenticationRequired.new ],
18
+ # [ %r{/upload/.*}, WEBrick::HTTPAuth::NotPermitted.new ],
19
+ # [ %r{/(edit|save)/home page}, WEBrick::HTTPAuth::SiteWidePassword.new('password','You need to enter the site wide password to edit the home page') ],
20
+ # [ %r{/(view|edit|save)/private.*},WEBrick::HTTPAuth::BasicAuth.new( :UserDB => htpasswd, :Realm => realm ) ], # See webrick documentation
21
+ [ %r{.*}, WEBrick::HTTPAuth::AskForUserName.new( 'No password, just enter a name') ]
22
+ ]
23
+ =end
24
+
25
+ CUSTOMSETTINGS = {
26
+ :root_directory => '<%= settings[:root_directory] %>',
27
+ # :name => 'test',
28
+ # :description => 'A Soks Wiki',
29
+ :url => '<%= settings[:url] %>',
30
+ :port => <%= settings[:port] %>,
31
+ # :authenticators => authenticators
32
+ }
33
+
34
+ def self.start
35
+ start_wiki( CUSTOMSETTINGS ) do |wiki, view|
36
+ AutomaticRecentChanges.new( wiki )
37
+
38
+ AutomaticOnePageIndex.new( wiki ) # Index on one page, best for small wikis
39
+ # AutomaticMultiPageIndex.new( wiki ) # One page per letter index, best for large wikis
40
+
41
+ # calendar = AutomaticCalendar.new( wiki ) # Adds a series of calendar pages to the wiki
42
+ # AutomaticUpcomingEvents.new( wiki, calendar ) # Creates a page with the next weeks events drawn from the calendar pages
43
+
44
+ # Examples of automatically generated summary pages:
45
+ AutomaticSummary.new( wiki,
46
+ :regexp_for_title => /^How to /i,
47
+ :pagename => 'Instructions and Howtos'
48
+ )
49
+
50
+ AutomaticSummary.new( wiki,
51
+ :regexp_for_title => /^Bug:/i,
52
+ :pagename => 'Known bugs',
53
+ :include_metadata => true
54
+ )
55
+
56
+ AutomaticSummary.new( wiki,
57
+ :regexp_for_title => /^Blog:/i,
58
+ :max_pages_to_show => 10,
59
+ :lines_to_include => 10,
60
+ :include_metadata => true,
61
+ :pagename => 'Recent Blog Entries'
62
+ )
63
+
64
+
65
+ # Possible settings for the Automatic Summary (with defaults)
66
+ # :regexp_for_title => /.*/, # These three regexps act as an AND
67
+ # :regexp_for_author => nil,
68
+ # :regexp_for_content => nil,
69
+ # :max_pages_to_show => nil,
70
+ # :pagename => 'Summary',
71
+ # :author => 'AutomaticSummary',
72
+ # :lines_to_include => nil, # nil puts a link, can pass a block instead to render
73
+ # :only_new_pages => false,
74
+ # :sort_pages_by => :created_on, # Could be :revised_on or :score or :name or :name_for_index, or :author
75
+ # :reverse_sort => false,
76
+ # :include_metadata => false, # Includes author and time in summary
77
+ # :summarise_revisions => false, # If true, then can contain several revisions for same page
78
+ # :remove_deleted_pages => true, # If false will keep references to deleted pages
79
+
80
+ # This is an array of titles that will NOT be automatically linked.
81
+ # Default is the 30 most common words in the english language
82
+ # Note that pages can still be created with these titles, and they can still be manually linked to.
83
+ banned_titles = IO.readlines('<%= settings[:root_directory] %>/banned_titles.txt').map { |title| title.strip }
84
+
85
+ # This takes a while, so do it last. Note that the banned_titles argument is optional.
86
+ AutomaticUpdateCrossLinks.new( wiki, view, banned_titles )
87
+ end
88
+ end
89
+
90
+ end
91
+
92
+ if $0 == __FILE__ then
93
+ StartSoks::start
94
+ end
@@ -0,0 +1 @@
1
+ 0.0.3
@@ -0,0 +1,61 @@
1
+ <span class='pagename'><%= pagename %> <%= page.deleted? ? "(Deleted)" : '' %></span>
2
+ <form method=post action='/save/<%= pagename %>' >
3
+ <table>
4
+ <tr>
5
+ <td>Title:</td>
6
+ <td><input name='newtitle' size = '60' value='<%= pagename %>' onClick="this.value == 'Type a title here' ? this.value = '' : true"/></td>
7
+ </tr>
8
+
9
+ <tr>
10
+ <td valign='top'>Content:</td>
11
+ <td>
12
+ <textarea name='content' rows=30 cols=60 onClick="this.value == 'Type what you want here and click save' ? this.value = '' : true" ><%= page.content %></textarea>
13
+ </td>
14
+ <td valign='top'>
15
+ <div class='tips'>
16
+ <ul>
17
+ <li>h1. big heading</li>
18
+ <li>h2. little heading</li>
19
+ <li>*bold text* = <b>bold text</b></li>
20
+ <li>_italic text_ = <i>italic text</i></li>
21
+ <li>* bullet one = &#8226; bullet one<br />
22
+ * bullet two = &#8226; bullet two</li>
23
+ <li># list one = 1. list one<br />
24
+ # list two = 2. list two</li>
25
+ <li>Most links are automatic</li>
26
+ <li>[[insert picture of title of picture]]</li>
27
+ <li><a href='http://hobix.com/textile/quick.html' target='textile_ref'>More</a></li>
28
+ </ul>
29
+ </div>
30
+ <td>
31
+ </tr>
32
+ <tr>
33
+ <td>Author:</td>
34
+ <td><a href='/<%= person %>'><%= person %></a> Quit browser to log out.</td>
35
+ </tr>
36
+ <tr>
37
+ <td></td>
38
+ <td><input name=action value='Save' type=submit accesskey="S"> <a href='/<%= pagename %>' accesskey="C" >(Do not Save)</a> or <a href='/delete/<%= pagename %>' accesskey='D'>(Delete)</a> this page.</td>
39
+ </tr>
40
+ </table>
41
+ </form>
42
+ <hr />
43
+ <% unless page.empty? %>
44
+ <p>The most recent change was made by <a href='/<%= page.author %>'><%= page.author %></a> who changed:</p>
45
+ <%
46
+ page.changes.each do |change_group|
47
+ change_group.each do |change|
48
+ case change[0]
49
+ when "-" %>
50
+ <del><%= change[1] %>. <%= change[2] %></del><br />
51
+ <% when "+" %>
52
+ <%= change[1] %>. <%= change[2] %><br />
53
+ <%
54
+ end
55
+ end
56
+ end
57
+ %>
58
+ <p>
59
+ <a href='/rollback/<%= pagename %>?revision=<%= page.number-1 %>' accesskey="U" >(Undo this change)</a> or <a href='/revisions/<%= pagename %>' accesskey="A" >(Show All changes)</a>
60
+ </p>
61
+ <% end %>
@@ -0,0 +1,40 @@
1
+ <span class='pagename'><a href='/<%= pagename %>'><%= pagename %></a> <%= page.deleted? ? "(Deleted)" : '' %></span>
2
+
3
+ <h1><%= pagename %></h1>
4
+
5
+ <p>This page was created on <%= page.created_on %> by <%= page.revisions.first.author %>.</p>
6
+ <p>It was last updated on <%= page.revised_on %> by <%= page.author %>.</p>
7
+ <p> It has been changed <%= page.revisions.size %> time(s) (roughly once every <%= (((Time.now-page.created_on)/page.revisions.size)/(60*60*24)).to_i %> days).</p>
8
+
9
+ <div class='metacolumn' >
10
+ <h2>Wiki links from this page</h2>
11
+
12
+ <ul>
13
+ <% page.links_from.each do |linkedpage| %>
14
+ <li><a href='/<%= linkedpage.name %>'><%= linkedpage.name %></a></li>
15
+ <% end %>
16
+ </ul>
17
+
18
+ </div>
19
+
20
+ <div class='metacolumn' >
21
+ <h2>Wiki links to this page</h2>
22
+
23
+ <ul>
24
+ <% page.links_to.each do |linkedpage| %>
25
+ <li><a href='/<%= linkedpage.name %>'><%= linkedpage.name %></a></li>
26
+ <% end %>
27
+ </ul>
28
+
29
+ </div>
30
+
31
+ <div class='metacolumn' >
32
+ <h2>Authors</h2>
33
+
34
+ <ol>
35
+ <% page.revisions.each do |revision| %>
36
+ <li><a href='/<%= revision.author %>'><%= revision.author %></a></li>
37
+ <% end %>
38
+ </ol>
39
+
40
+ </div>
@@ -0,0 +1,6 @@
1
+ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
2
+ <html xmlns="http://www.w3.org/1999/xhtml">
3
+ <body>
4
+ <%= renderedview %>
5
+ </body>
6
+ </html>
@@ -0,0 +1,19 @@
1
+ <span class='pagename'><%= pagename %></span>
2
+ <div class="undochange">
3
+ <% page.revisions.reverse_each do |revision| %>
4
+ <p><%= revision.created_on %> by <a href='/<%= revision.author %>'><%= revision.author %></a> <a href='/rollback/<%= pagename %>?revision=<%= revision.number-1 %>' >(undo)</a>:</p>
5
+ <p>
6
+ <% revision.changes.each do |change_group| %>
7
+ <% change_group.each do |change|
8
+ case change[0]
9
+ when "-" %>
10
+ <del><%= change[1] %>. <%= change[2] %></del><br />
11
+ <% when "+" %>
12
+ <%= change[1] %>. <%= change[2] %><br />
13
+ <% end %>
14
+ <% end %>
15
+ <% end %>
16
+ </p>
17
+ <% end %>
18
+ <br />(<a href='/edit/<%= pagename %>' accesskey="R" >Return to editing</a>)
19
+ </div>
@@ -0,0 +1,55 @@
1
+ <%=
2
+ require "rss/maker"
3
+
4
+ RSS::Maker.make("2.0") do |maker|
5
+
6
+ maker.channel.title = "#{$SETTINGS[:name]} #{pagename}"
7
+ maker.channel.description = $SETTINGS[:description]
8
+ maker.channel.link = $SETTINGS[:url]
9
+
10
+ maker.image.title = "#{$SETTINGS[:name]}"
11
+ maker.image.url = "#{$SETTINGS[:url]}/attachment/logo.png"
12
+
13
+ maker.textinput.title = "Search"
14
+ maker.textinput.description = "Search #{$SETTINGS[:name]}'s text"
15
+ maker.textinput.name = "regex"
16
+ maker.textinput.link = "#{$SETTINGS[:url]}/find/searchpage"
17
+
18
+ maker.items.do_sort = true
19
+
20
+ count = 0
21
+ for revision in page.revisions
22
+ break if (count +=1) == 15
23
+ item = maker.items.new_item
24
+ item.link = "#{$SETTINGS[:url]}/#{pagename}"
25
+ # Get the first change that makes an addition and use as the title
26
+ title = nil
27
+ revision.changes.each do |group|
28
+ group.each do |type,line,text|
29
+ if type == '+' && text != ''
30
+ title = text.gsub(/<.*?>/,'')
31
+ end
32
+ break if title
33
+ end
34
+ break if title
35
+ end
36
+ # If change found, take just the changed text and remove tags.
37
+ # If no change found, then must be because only deleted stuff so give that message
38
+ item.title = title || $MESSAGES[:some_content_has_been_deleted] # Default
39
+ item.date = revision.created_on
40
+ item.author = revision.author
41
+ item.description = ""
42
+ content_deleted = false
43
+ revision.changes.each do |change_group|
44
+ change_group.each do |change|
45
+ case change[0]
46
+ when "-"; content_deleted = true
47
+ when "+"; item.description << "#{change[2]}<br />"
48
+ end
49
+ end
50
+ item.description << "&#8230;<br />"
51
+ end
52
+ item.description << "Content was also deleted" if content_deleted
53
+ end
54
+ end
55
+ %>
@@ -16,4 +16,4 @@
16
16
  <% end %>
17
17
  </ul>
18
18
  <% end %>
19
- <br/>(<a href='/edit/<%= pagename %>' accesskey="E" >Create a page titled &#8220;<%= pagename %>&#8221;</a>)
19
+ <div class='command'>(<a href='/edit/<%= pagename %>' accesskey="E" >Create a page titled &#8220;<%= pagename %>&#8221;</a>)</div>
@@ -0,0 +1,4 @@
1
+ <span class='pagename'><a href='/meta/<%= pagename %>'><%= pagename %></a> <%= page.deleted? ? "(Deleted)" : '' %></span>
2
+
3
+ <%= renderedview %>
4
+ <div class='command'><a href='/edit/<%= pagename %>' accesskey="E" >(Edit this page)</a></div>
@@ -0,0 +1,38 @@
1
+ <span class='pagename'><%= pagename %><%= page.deleted? ? "(Deleted)" : '' %></span>
2
+
3
+ <form action='/upload/<%= pagename %>' method=post enctype=multipart/form-data >
4
+ <table>
5
+ <tr><td>Title:</td><td>
6
+ <% if page.is_a? ImagePage %>
7
+ <input type=hidden name='titleprefix' value='Picture of ' />
8
+ Picture of <input name='newtitle' size = '51' value='<%= pagename[ 10..-1].strip %>'
9
+ <% else %>
10
+ <input type=hidden name='titleprefix' value='Attached ' />
11
+ Attached <input name='newtitle' size = '52' value='<%= pagename[ 9..-1].strip %>'
12
+ <% end %>
13
+ onClick="this.value == 'Type a title here' ? this.value = '' : true"/></td></tr>
14
+ <tr><td valign='top'>File:</td><td><input name='file' type=file /></td></tr>
15
+ <tr><td>Author:</td><td><a href='/<%= person %>'><%= person %></a> Quit browser to log out.</td>
16
+ <tr><td></td><td><input name=action value='Save' type=submit accesskey="S"> <a href='/<%= pagename %>' accesskey="C" >(Cancel)</a> or <a href='/delete/<%= pagename %>' accesskey='D'>(Delete)</a> this page.</td></tr>
17
+ </table>
18
+ </form>
19
+ <hr />
20
+ <% unless page.empty? %>
21
+ <p>The most recent change was made by <a href='/<%= page.author %>'><%= page.author %></a> who changed:</p>
22
+ <%
23
+ page.changes.each do |change_group|
24
+ change_group.each do |change|
25
+ case change[0]
26
+ when "-" %>
27
+ <del><%= change[1] %>. <%= change[2] %></del><br />
28
+ <% when "+" %>
29
+ <%= change[1] %>. <%= change[2] %><br />
30
+ <%
31
+ end
32
+ end
33
+ end
34
+ %>
35
+ <p>
36
+ <a href='/rollback/<%= pagename %>?revision=<%= page.number - 1 %>' accesskey="U" >(Undo this change)</a> or <a href='/revisions/<%= pagename %>' accesskey="A" >(Show All changes)</a>
37
+ </p>
38
+ <% end %>
@@ -0,0 +1,41 @@
1
+ <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
2
+ <html>
3
+ <head>
4
+ <title><%= pagename %></title>
5
+ <meta name='description' content='<%= $SETTINGS[:description] %>' />
6
+ <meta name='keywords' content='Soks, <%= $SETTINGS[:name] %>' />
7
+ <link href='/attachment/stylesheet.css' rel='stylesheet' type='text/css' media='screen' />
8
+ <link href='/attachment/print_stylesheet.css' rel='stylesheet' type='text/css' media='print' />
9
+ <link rel='alternate' type='application/rss+xml' title='RSS' href='/rss/<%= pagename %>' />
10
+ <script src='/attachment/newpage.js' type='text/javascript'></script>
11
+ </head>
12
+ <body onkeypress='hotkey(event);'>
13
+ <div id='content'>
14
+ <%= content_of_page %>
15
+ </div>
16
+ <div id='menu'>
17
+ <a href='/Home Page' accesskey='H' ><img width='149' src='/attachment/logo.png' alt='<%= @wikiname %>' /></a>
18
+ <form method='get' action='/find/<%= pagename %>' >
19
+ <input name='regex' value='' size='18' />
20
+ <input name='action' value='search' type='submit' />
21
+ </form>
22
+ <a href='/site index' accesskey='I' >Site Index</a>
23
+ <a href='/recent changes to this site' accesskey='R' >Recent Changes</a>
24
+ <% if page %>
25
+ <% page.links_to.each do |linkedpage| %>
26
+ <a href='/<%= linkedpage.name %>'><%= linkedpage.name %></a>
27
+ <% end %>
28
+ <% end %>
29
+ <br />
30
+ <a href='/edit/Type a title here'>Add a new page</a>
31
+ <a href='/edit/Picture of Type a title here'>Upload a new picture</a>
32
+ <a href='/edit/Attached Type a title here'>Upload a new file</a>
33
+ <br />
34
+ <span class='disclaimer'>
35
+ This website can be edited by anyone. It is therefore unlikely to represent the views of anyone named.
36
+ </span>
37
+ <br />
38
+ <a style='display:inline;' href='/rss/<%= pagename %>'><img src='/attachment/rss.png' alt='rss feed' /></a>
39
+ </div>
40
+ </body>
41
+ </html>
@@ -0,0 +1,6 @@
1
+ :some_content_has_been_deleted : "Some content has been deleted"
2
+ :Type_what_you_want_here_and_click_save : "Type what you want here and click save"
3
+ :Create : "Create"
4
+ :page_deleted : "page deleted"
5
+ :content_moved_to : "content moved to"
6
+ :content_moved_from : "content moved from"
@@ -0,0 +1,199 @@
1
+ #Container {
2
+ float: none;
3
+ margin: 0 auto;
4
+ text-align: center;
5
+ }
6
+
7
+ #Content {
8
+ margin: 0;
9
+ padding: 5px;
10
+ text-align: left;
11
+ border-top: none;
12
+ float: left;
13
+ }
14
+
15
+ body { background-color: #fff; color: #333; }
16
+
17
+ body, p, ol, ul, td {
18
+ font-family: verdana, arial, helvetica, sans-serif;
19
+ font-size: 13px;
20
+ line-height: 18px;
21
+ }
22
+
23
+ a { color: #000; }
24
+
25
+ .newWikiWord { background-color: #eee; }
26
+ .newWikiWord a:hover { background-color: white; }
27
+
28
+ a:visited { color: #666; }
29
+ a:hover { color: #fff; background-color:#000; }
30
+
31
+ /* a.edit:link, a.edit:visited { color: #DA0006; } */
32
+
33
+
34
+ h1, h2, h3 { color: #333; font-family: georgia, verdana; }
35
+ h1 { font-size: 28px }
36
+ h2 { font-size: 19px }
37
+ h3 { font-size: 16px }
38
+
39
+ h1#pageName {
40
+ margin: 5px 0px 0px 0px;
41
+ padding: 0px 0px 0px 0px;
42
+ line-height: 28px;
43
+ }
44
+
45
+ h1#pageName small {
46
+ color: grey;
47
+ line-height: 10px;
48
+ font-size: 10px;
49
+ padding: 0px;
50
+ }
51
+
52
+ a.nav, a.nav:link, a.nav:visited { color: #000; }
53
+ a.nav:hover { color: #fff; background-color:#000; }
54
+
55
+ li { margin-bottom: 7px }
56
+
57
+ .navigation {
58
+ margin-top: 5px;
59
+ font-size : 12px;
60
+ color: #999;
61
+ }
62
+
63
+ .navigation a:hover { color: #fff; background-color:#000; }
64
+
65
+ .navigation a {
66
+ font-size: 11px;
67
+ color: black;
68
+ font-weight: bold;
69
+ }
70
+
71
+ .navigation small a {
72
+ font-weight: normal;
73
+ font-size: 11px;
74
+ }
75
+
76
+ .navOn{
77
+ font-size: 11px;
78
+ color: grey;
79
+ font-weight: bold;
80
+ text-decoration: none;
81
+ }
82
+
83
+ .help {
84
+ font-family: verdana, arial, helvetica, sans-serif;
85
+ font-size: 11px;
86
+ }
87
+
88
+ .inputBox {
89
+ font-family: verdana, arial, helvetica, sans-serif;
90
+ font-size: 11px;
91
+ background-color: #eee;
92
+ padding: 5px;
93
+ margin-bottom: 20px;
94
+ }
95
+
96
+ blockquote {
97
+ display: block;
98
+ margin: 0px 0px 20px 0px;
99
+ padding: 0px 30px;
100
+ font-size:11px;
101
+ line-height:17px;
102
+ font-style: italic;
103
+ }
104
+
105
+ pre {
106
+ background-color: #eee;
107
+ padding: 10px;
108
+ font-size: 11px;
109
+ }
110
+
111
+ ol.setup {
112
+ font-size: 19px;
113
+ font-family: georgia, verdana;
114
+ padding-left: 25px;
115
+ }
116
+
117
+ ol.setup li {
118
+ margin-bottom: 20px
119
+ }
120
+
121
+ .byline {
122
+ font-size: 10px;
123
+ font-style: italic;
124
+ margin-bottom: 10px;
125
+ color: #999;
126
+ }
127
+
128
+ .references {
129
+ font-size: 10px;
130
+ }
131
+
132
+ .diffdel {
133
+ background: pink;
134
+ }
135
+
136
+ .diffins {
137
+ background: lightgreen;
138
+ }
139
+
140
+ #TextileHelp table {
141
+ margin-bottom: 0;
142
+ }
143
+
144
+ #TextileHelp table+h3 {
145
+ margin-top: 11px;
146
+ }
147
+
148
+ #TextileHelp table td {
149
+ font-size: 11px;
150
+ padding: 3px;
151
+ vertical-align: top;
152
+ border-top: 1px dotted #ccc;
153
+ }
154
+
155
+ #TextileHelp table td.arrow {
156
+ padding-right: 5px;
157
+ padding-left: 10px;
158
+ color: #999;
159
+ }
160
+
161
+ #TextileHelp table td.label {
162
+ font-weight: bold;
163
+ white-space: nowrap;
164
+ font-size: 10px;
165
+ padding-right: 15px;
166
+ color: #000;
167
+ }
168
+
169
+ #TextileHelp h3 {
170
+ font-size: 11px;
171
+ font-weight: bold;
172
+ font-weight: normal;
173
+ margin: 0 0 5px 0;
174
+ padding: 5px 0 0 0;
175
+ }
176
+
177
+ #TextileHelp p {
178
+ font-size: 10px;
179
+ }
180
+
181
+ .rightHandSide {
182
+ float: right;
183
+ width: 147px;
184
+ margin-left: 10px;
185
+ padding-left: 20px;
186
+ border-left: 1px dotted #ccc;
187
+ }
188
+
189
+ .rightHandSide p {
190
+ font-size: 10px;
191
+ }
192
+
193
+ .newsList {
194
+ margin-top: 20px;
195
+ }
196
+
197
+ .newsList p {
198
+ margin-bottom:30px
199
+ }