baseline
[omp.pkp.sfu.ca.git] / lib / pkp / templates / install / install.tpl
blob26f7bc9028d314c9b2f53fc2e8b557c42f56c284
1 {**
2  * install.tpl
3  *
4  * Copyright (c) 2000-2009 John Willinsky
5  * Distributed under the GNU GPL v2. For full terms see the file docs/COPYING.
6  *
7  * Installation form.
8  *
9  * $Id: install.tpl,v 1.6 2009/08/18 23:44:09 asmecher Exp $
10  *}
11 {strip}
12 {include file="common/header.tpl"}
13 {/strip}
15 <script type="text/javascript">
16 {literal}
17 <!--
18 // Ensure that the form submit button cannot be double-clicked
19 function doSubmit() {
20         if (document.install.installing.value != 1) {
21                 document.install.installing.value = 1;
22                 document.install.submit();
23         }
24         return true;
26 // -->
27 {/literal}
28 </script>
30 {if is_writeable('config.inc.php')}{translate|assign:"writable_config" key="installer.checkYes"}{else}{translate|assign:"writable_config" key="installer.checkNo"}{/if}
31 {if is_writeable('cache')}{translate|assign:"writable_cache" key="installer.checkYes"}{else}{translate|assign:"writable_cache" key="installer.checkNo"}{/if}
32 {if is_writeable('public')}{translate|assign:"writable_public" key="installer.checkYes"}{else}{translate|assign:"writable_public" key="installer.checkNo"}{/if}
33 {if is_writeable('cache/_db')}{translate|assign:"writable_db_cache" key="installer.checkYes"}{else}{translate|assign:"writable_db_cache" key="installer.checkNo"}{/if}
34 {if is_writeable('cache/t_cache')}{translate|assign:"writable_templates_cache" key="installer.checkYes"}{else}{translate|assign:"writable_templates_cache" key="installer.checkNo"}{/if}
35 {if is_writeable('cache/t_compile')}{translate|assign:"writable_templates_compile" key="installer.checkYes"}{else}{translate|assign:"writable_templates_compile" key="installer.checkNo"}{/if}
37 {if !$phpIsSupportedVersion}
38         {translate|assign:"wrongPhpText" key="installer.installationWrongPhp"}
39 {/if}
41 {url|assign:"upgradeUrl" page="install" op="upgrade"}
42 {translate key="installer.installationInstructions" version=$version->getVersionString() upgradeUrl=$upgradeUrl baseUrl=$baseUrl writable_config=$writable_config writable_db_cache=$writable_db_cache writable_cache=$writable_cache writable_public=$writable_public writable_templates_cache=$writable_templates_cache writable_templates_compile=$writable_templates_compile phpRequiredVersion=$phpRequiredVersion wrongPhpText=$wrongPhpText phpVersion=$phpVersion}
44 <div class="separator"></div>
46 <form method="post" name="install" action="{url op="install"}">
47 <input type="hidden" name="installing" value="0" />
48 {include file="common/formErrors.tpl"}
50 {if $isInstallError}
51 <p>
52         <span class="formError">{translate key="installer.installErrorsOccurred"}:</span>
53         <ul class="formErrorList">
54                 <li>{if $dbErrorMsg}{translate key="common.error.databaseError" error=$dbErrorMsg}{else}{translate key=$errorMsg}{/if}</li>
55         </ul>
56 </p>
57 {/if}
59 <div id="localeSettings">
60 <h3>{translate key="installer.localeSettings"}</h3>
62 <p>{translate key="installer.localeSettingsInstructions" supportsMBString=$supportsMBString}</p>
64 <table width="100%" class="data">
65         <tr valign="top">
66                 <td width="20%" class="label">{fieldLabel name="locale" key="locale.primary"}</td>
67                 <td width="80%" class="value">
68                         <select name="locale" id="locale" size="1" class="selectMenu">
69                                 {html_options options=$localeOptions selected=$locale}
70                         </select>
71                         <br />
72                         <span class="instruct">{translate key="installer.localeInstructions"}</span>
73                 </td>
74         </tr>
75         <tr valign="top">
76                 <td class="label">{fieldLabel suppressId="true" name="additionalLocales" key="installer.additionalLocales"}</td>
77                 <td class="value">
78                         {foreach from=$localeOptions key=localeKey item=localeName}
79                                 <input type="checkbox" name="additionalLocales[]" id="additionalLocales-{$localeKey|escape}" value="{$localeKey|escape}"{if in_array($localeKey, $additionalLocales)} checked="checked"{/if} /> <label for="additionalLocales-{$localeKey|escape}">{$localeName|escape} ({$localeKey|escape})</label>
80                                 {if !$localesComplete[$localeKey]}
81                                         <span class="formError">*</span>
82                                         {assign var=incompleteLocaleFound value=1}
83                                 {/if}<br />
84                         {/foreach}
85                         <span class="instruct">{translate key="installer.additionalLocalesInstructions"}</span>
86                         {if $incompleteLocaleFound}
87                                 <br/>
88                                 <span class="formError">*</span>&nbsp;{translate key="installer.locale.maybeIncomplete"}
89                         {/if}{* $incompleteLocaleFound *}
90                 </td>
91         </tr>
92         <tr valign="top">
93                 <td class="label">{fieldLabel name="clientCharset" key="installer.clientCharset"}</td>
94                 <td class="value">
95                         <select name="clientCharset" id="clientCharset" size="1" class="selectMenu">
96                                 {html_options options=$clientCharsetOptions selected=$clientCharset}
97                         </select>
98                         <br />
99                         <span class="instruct">{translate key="installer.clientCharsetInstructions"}</span>
100                 </td>
101         </tr>
102         <tr valign="top">
103                 <td class="label">{fieldLabel name="connectionCharset" key="installer.connectionCharset"}</td>
104                 <td class="value">
105                         <select name="connectionCharset" id="connectionCharset" size="1" class="selectMenu">
106                                 {html_options options=$connectionCharsetOptions selected=$connectionCharset}
107                         </select>
108                         <br />
109                         <span class="instruct">{translate key="installer.connectionCharsetInstructions"}</span>
110                 </td>
111         </tr>
112         <tr valign="top">
113                 <td class="label">{fieldLabel name="databaseCharset" key="installer.databaseCharset"}</td>
114                 <td class="value">
115                         <select name="databaseCharset" id="databaseCharset" size="1" class="selectMenu">
116                                 {html_options options=$databaseCharsetOptions selected=$databaseCharset}
117                         </select>
118                         <br />
119                         <span class="instruct">{translate key="installer.databaseCharsetInstructions"}</span>
120                 </td>
121         </tr>
122 </table>
123 </div>
125 <div class="separator"></div>
127 {if !$skipFilesDirSection}
128 <div id="fileSettings">
129         <h3>{translate key="installer.fileSettings"}</h3>
131         <table width="100%" class="data">
132                 <tr valign="top">
133                         <td width="20%" class="label">{fieldLabel name="filesDir" key="installer.filesDir"}</td>
134                         <td width="80%" class="value">
135                                 <input type="text" name="filesDir" id="filesDir" value="{$filesDir|escape}" size="60" maxlength="255" class="textField" />
136                                 <br />
137                                 <span class="instruct">{translate key="installer.filesDirInstructions"}</span>
138                         </td>
139                 </tr>
140                 <tr valign="top">
141                         <td>&nbsp;</td>
142                         <td class="value"><input type="checkbox" name="skipFilesDir" id="skipFilesDir" value="1"{if $skipFilesDir} checked="checked"{/if} /> <label for="skipFilesDir">{translate key="installer.skipFilesDir"}</label></td>
143                 </tr>
144         </table>
146         <div class="separator"></div>
147 </div>
148 {/if}{* !$skipFilesDirSection *}
150 <div id="security">
151 <h3>{translate key="installer.securitySettings"}</h3>
153 <table width="100%" class="data">
154         <tr valign="top">
155                 <td width="20%" class="label">{fieldLabel name="encryption" key="installer.encryption"}</td>
156                 <td width="80%" class="value">
157                         <select name="encryption" id="encryption" size="1" class="selectMenu">
158                                 {html_options options=$encryptionOptions selected=$encryption}
159                         </select>
160                         <br />
161                         <span class="instruct">{translate key="installer.encryptionInstructions"}</span>
162                 </td>
163         </tr>
164 </table>
165 </div>
167 <div class="separator"></div>
169 <div id="administratorAccount">
170 <h3>{translate key="installer.administratorAccount"}</h3>
172 <p>{translate key="installer.administratorAccountInstructions"}</p>
174 <table width="100%" class="data">
175         <tr valign="top">
176                 <td width="20%" class="label">{fieldLabel name="adminUsername" key="user.username"}</td>
177                 <td width="80%" class="value"><input type="text" name="adminUsername" id="adminUsername" value="{$adminUsername|escape}" size="20" maxlength="32" class="textField" /></td>
178         </tr>
179         <tr valign="top">
180                 <td class="label">{fieldLabel name="adminPassword" key="user.password"}</td>
181                 <td class="value"><input type="password" name="adminPassword" id="adminPassword" value="{$adminPassword|escape}" size="20" maxlength="32" class="textField" /></td>
182         </tr>
183         <tr valign="top">
184                 <td class="label">{fieldLabel name="adminPassword2" key="user.register.repeatPassword"}</td>
185                 <td class="value"><input type="password" name="adminPassword2" id="adminPassword2" value="{$adminPassword2|escape}" size="20" maxlength="32" class="textField" /></td>
186         </tr>
187         <tr valign="top">
188                 <td width="20%" class="label">{fieldLabel name="adminEmail" key="user.email"}</td>
189                 <td width="80%" class="value"><input type="text" name="adminEmail" id="adminEmail" value="{$adminEmail|escape}" size="30" maxlength="90" class="textField" /></td>
190         </tr>
191 </table>
192 </div>
194 <div class="separator"></div>
196 <div id="databaseSettings">
197 <h3>{translate key="installer.databaseSettings"}</h3>
199 <p>{translate key="installer.databaseSettingsInstructions"}</p>
201 <table width="100%" class="data">
202         <tr valign="top">
203                 <td width="20%" class="label">{fieldLabel name="databaseDriver" key="installer.databaseDriver"}</td>
204                 <td width="80%" class="value">
205                         <select name="databaseDriver" id="databaseDriver" size="1" class="selectMenu">
206                                 {html_options options=$databaseDriverOptions selected=$databaseDriver}
207                         </select>
208                         <br />
209                         <span class="instruct">{translate key="installer.databaseDriverInstructions"}</span>
210                 </td>
211         </tr>
212         <tr valign="top">
213                 <td class="label">{fieldLabel name="databaseHost" key="installer.databaseHost"}</td>
214                 <td class="value">
215                         <input type="text" name="databaseHost" id="databaseHost" value="{$databaseHost|escape}" size="30" maxlength="60" class="textField" />
216                         <br />
217                         <span class="instruct">{translate key="installer.databaseHostInstructions"}</span>
218                 </td>
219         </tr>
220         <tr valign="top">
221                 <td class="label">{fieldLabel name="databaseUsername" key="installer.databaseUsername"}</td>
222                 <td class="value"><input type="text" name="databaseUsername" id="databaseUsername" value="{$databaseUsername|escape}" size="30" maxlength="60" class="textField" /></td>
223         </tr>
224         <tr valign="top">
225                 <td class="label">{fieldLabel name="databasePassword" key="installer.databasePassword"}</td>
226                 <td class="value"><input type="text" name="databasePassword" id="databasePassword" value="{$databasePassword|escape}" size="30" maxlength="60" class="textField" /></td>
227         </tr>
228         <tr valign="top">
229                 <td class="label">{fieldLabel name="databaseName" key="installer.databaseName"}</td>
230                 <td class="value"><input type="text" name="databaseName" id="databaseName" value="{$databaseName|escape}" size="30" maxlength="60" class="textField" /></td>
231         </tr>
232         <tr valign="top">
233                 <td>&nbsp;</td>
234                 <td class="value">
235                         <input type="checkbox" name="createDatabase" id="createDatabase" value="1"{if $createDatabase} checked="checked"{/if} /> <label for="createDatabase">{translate key="installer.createDatabase"}</label>
236                         <br />
237                         <span class="instruct">{translate key="installer.createDatabaseInstructions"}</span>
238                 </td>
239         </tr>
240 </table>
241 </div>
243 <div class="separator"></div>
245 {if !$skipMiscSettings}
246 <div id="miscSettings">
247 <h3>{translate key="installer.miscSettings"}</h3>
249         <table width="100%" class="data">
250                 <tr valign="top">
251                         <td width="20%" class="label">{fieldLabel name="oaiRepositoryId" key="installer.oaiRepositoryId"}</td>
252                         <td width="80%" class="value">
253                                 <input type="text" name="oaiRepositoryId" id="oaiRepositoryId" value="{$oaiRepositoryId|escape}" size="30" maxlength="60" class="textField" />
254                                 <br />
255                                 <span class="instruct">{translate key="installer.oaiRepositoryIdInstructions"}</span>
256                         </td>
257                 </tr>
258         </table>
260         <div class="separator"></div>
261 </div>
262 {/if}{* !$skipMiscSettings *}
264 <p><input name="install" type="button" id="install" value="{translate key="installer.installApplication"}" class="button defaultButton" onclick="doSubmit()" /> <input type="submit" name="manualInstall" value="{translate key="installer.manualInstall"}" class="button" /></p>
266 </form>
268 {include file="common/footer.tpl"}