2005-01-24 19:52:04 +01:00
|
|
|
<% @title = "Edit Web" %>
|
|
|
|
|
2005-05-05 08:26:47 +02:00
|
|
|
<%= form_tag({ :controller => 'admin', :action => 'edit_web', :web => @web.address },
|
|
|
|
{'id' => 'setup', 'method' => 'post', 'onSubmit' => 'cleanAddress(); return validateSetup()'})
|
|
|
|
%>
|
|
|
|
|
2005-01-24 19:52:04 +01:00
|
|
|
<h2 style="margin-bottom: 3px">Name and address</h2>
|
|
|
|
<div class="help">
|
|
|
|
The name of the web is included in the title on all pages.
|
|
|
|
The address is the base path that all pages within the web live beneath.
|
|
|
|
Ex: the address "rails" gives URLs like <i>/rails/show/HomePage</i>.
|
|
|
|
</div>
|
|
|
|
|
2005-11-14 15:02:36 +01:00
|
|
|
<div class="inputBox">
|
|
|
|
Name: <input type="text" id="name" name="name" class="disableAutoComplete" value="<%= @web.name %>"
|
2005-01-24 19:52:04 +01:00
|
|
|
onChange="proposeAddress();" />
|
2005-11-14 15:02:36 +01:00
|
|
|
Address: <input type="text" class="disableAutoComplete" id="address" name="address" value="<%= @web.address %>"
|
2005-01-24 19:52:04 +01:00
|
|
|
onChange="cleanAddress();" />
|
2005-11-14 15:02:36 +01:00
|
|
|
<small><em>(Letters and digits only)</em></small>
|
2005-01-24 19:52:04 +01:00
|
|
|
</div>
|
|
|
|
|
|
|
|
<h2 style="margin-bottom: 3px">Specialize</h2>
|
2005-11-14 15:02:36 +01:00
|
|
|
<div class="inputBox">
|
2005-01-24 19:52:04 +01:00
|
|
|
Markup:
|
|
|
|
<select name="markup">
|
2005-04-08 07:02:48 +02:00
|
|
|
<%= html_options({'Textile' => :textile, 'Markdown' => :markdown, 'Mixed' => :mixed,
|
|
|
|
'RDoc' => :rdoc }, @web.markup) %>
|
2005-01-24 19:52:04 +01:00
|
|
|
</select>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Color:
|
|
|
|
<select name="color">
|
2005-04-08 07:02:48 +02:00
|
|
|
<%= html_options({ 'Green' => '008B26', 'Purple' => '504685', 'Red' => 'DA0006',
|
|
|
|
'Orange' => 'FA6F00', 'Grey' => '8BA2B0' }, @web.color) %>
|
2005-01-24 19:52:04 +01:00
|
|
|
</select>
|
2005-01-30 07:11:00 +01:00
|
|
|
<br/>
|
|
|
|
<p>
|
2005-01-24 19:52:04 +01:00
|
|
|
<small>
|
2005-11-14 15:02:36 +01:00
|
|
|
<input type="checkbox" class="disableAutoComplete" name="safe_mode" <%= 'checked="on"' if @web.safe_mode %> />
|
2005-01-30 07:11:00 +01:00
|
|
|
Safe mode
|
|
|
|
<em>- strip HTML tags and stylesheet options from the content of all pages</em>
|
|
|
|
<br/>
|
2005-11-14 15:02:36 +01:00
|
|
|
<input type="checkbox" class="disableAutoComplete" name="brackets_only" <%= 'checked="on"' if @web.brackets_only %> />
|
2005-01-24 19:52:04 +01:00
|
|
|
Brackets only
|
2005-01-30 07:11:00 +01:00
|
|
|
<em>- require all wiki words to be as [[wiki word]], WikiWord links won't be created</em>
|
|
|
|
<br/>
|
2005-11-14 15:02:36 +01:00
|
|
|
<input type="checkbox" class="disableAutoComplete" name="count_pages" <%= 'checked="on"' if @web.count_pages %> />
|
2005-01-30 07:11:00 +01:00
|
|
|
Count pages
|
|
|
|
<br/>
|
2005-04-03 06:22:46 +02:00
|
|
|
|
2005-11-14 15:02:36 +01:00
|
|
|
<input type="checkbox" class="disableAutoComplete" name="allow_uploads" <%= 'checked="on"' if @web.allow_uploads %> />
|
2005-01-30 07:11:00 +01:00
|
|
|
Allow uploads of no more than
|
2005-11-14 15:02:36 +01:00
|
|
|
<input type="text" class="disableAutoComplete" name="max_upload_size" value="<%= @web.max_upload_size %>"
|
2005-01-30 07:11:00 +01:00
|
|
|
width="20" />
|
|
|
|
kbytes
|
|
|
|
<em>-
|
2005-03-24 02:18:41 +01:00
|
|
|
allow users to upload pictures and other files and include them on wiki pages
|
2005-01-30 07:11:00 +01:00
|
|
|
</em>
|
|
|
|
<br/>
|
2005-01-24 19:52:04 +01:00
|
|
|
</small>
|
2005-01-30 07:11:00 +01:00
|
|
|
</p>
|
2005-01-24 19:52:04 +01:00
|
|
|
|
2005-02-05 14:53:29 +01:00
|
|
|
<a href="#"
|
|
|
|
onClick="document.getElementById('additionalStyle').style.display='block';return false;">
|
2005-01-30 07:11:00 +01:00
|
|
|
Stylesheet tweaks >></a>
|
|
|
|
<small><em>
|
|
|
|
- add or change styles used by this web; styles defined here take precedence over
|
|
|
|
instiki.css. Hint: View HTML source of a page you want to style to find ID names on individual
|
|
|
|
tags.</em></small>
|
|
|
|
<br/>
|
2005-11-14 15:02:36 +01:00
|
|
|
<textarea id="additionalStyle" class="disableAutoComplete"
|
2005-01-24 19:52:04 +01:00
|
|
|
style="display: none; margin-top: 10px; margin-bottom: 5px; width: 560px; height: 200px"
|
|
|
|
name="additional_style"><%= @web.additional_style %>
|
|
|
|
</textarea>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<h2 style="margin-bottom: 3px">Password protection for this web (<%= @web.name %>)</h2>
|
|
|
|
<div class="help">
|
|
|
|
This is the password that visitors need to view and edit this web.
|
|
|
|
Setting the password to nothing will remove the password protection.
|
|
|
|
</div>
|
|
|
|
<div class="inputBox">
|
|
|
|
Password: <input class="disableAutoComplete" type="password" id="password"
|
|
|
|
name="password" value="<%= @web.password %>" />
|
|
|
|
|
|
|
|
Verify: <input class="disableAutoComplete" type="password" id="password_check"
|
|
|
|
value="<%= @web.password %>" name="password_check" />
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<h2 style="margin-bottom: 3px">Publish read-only version of this web (<%= @web.name %>)</h2>
|
|
|
|
<div class="help">
|
|
|
|
You can turn on a read-only version of this web that's accessible even when the regular web
|
|
|
|
is password protected.
|
|
|
|
The published version is accessible through URLs like /wiki/published/HomePage.
|
|
|
|
</div>
|
|
|
|
<div class="inputBox">
|
2005-11-14 15:02:36 +01:00
|
|
|
<input type="checkbox" name="published" class="disableAutoComplete" <%= 'checked="on"' if @web.published %> />
|
2005-02-05 14:53:29 +01:00
|
|
|
Publish this web
|
2005-01-24 19:52:04 +01:00
|
|
|
</div>
|
|
|
|
|
|
|
|
<p align="right">
|
|
|
|
<small>
|
|
|
|
Enter system password
|
2005-02-05 14:53:29 +01:00
|
|
|
<input type="password" class="disableAutoComplete" id="system_password"
|
|
|
|
name="system_password" />
|
2005-01-24 19:52:04 +01:00
|
|
|
and
|
|
|
|
<input type="submit" value="Update Web" />
|
|
|
|
<br/><br/>
|
2005-04-07 05:36:12 +02:00
|
|
|
...or forget changes and <%= link_to 'create a new web', :action => 'create_web' %>
|
2005-01-24 19:52:04 +01:00
|
|
|
</small>
|
|
|
|
</p>
|
|
|
|
|
2005-05-05 08:26:47 +02:00
|
|
|
<%= end_form_tag %>
|
2005-01-24 19:52:04 +01:00
|
|
|
|
|
|
|
<br/>
|
|
|
|
<h1>Other administrative tasks</h1>
|
|
|
|
|
2005-04-08 07:21:08 +02:00
|
|
|
<%= form_tag({:controller => 'admin', :web => @web.address, :action => 'remove_orphaned_pages'},
|
2005-04-09 05:05:37 +02:00
|
|
|
{:id => 'remove_orphaned_pages',
|
|
|
|
:onSubmit => "return checkSystemPassword(document.getElementById('system_password_orphaned').value)"
|
|
|
|
})
|
2005-04-08 07:21:08 +02:00
|
|
|
%>
|
2005-01-24 19:52:04 +01:00
|
|
|
<p align="right">
|
|
|
|
<small>
|
|
|
|
Clean up by entering system password
|
2005-11-14 15:02:36 +01:00
|
|
|
<input type="password" id="system_password_orphaned" class="disableAutoComplete" name="system_password_orphaned" />
|
2005-01-24 19:52:04 +01:00
|
|
|
and
|
|
|
|
<input type="submit" value="Delete Orphan Pages" />
|
|
|
|
</small>
|
|
|
|
</p>
|
2005-04-08 07:21:08 +02:00
|
|
|
<%= end_form_tag %>
|
2005-01-24 19:52:04 +01:00
|
|
|
|
2005-07-20 00:27:45 +02:00
|
|
|
<%= javascript_include_tag 'edit_web' %>
|