| 35 | | Syntax: MidgardParser [encoding] |
|---|
| 36 | | Example: MidgardParser russian |
|---|
| 37 | | The MidgardParser directive sets text formating engine used for internal |
|---|
| 38 | | text formating and mail message handling. You may select between 'latin1' |
|---|
| 39 | | and 'russian' values. 'latin1' does conversion of chars using ISO-8859-1 |
|---|
| 40 | | encoding and converts symbols higher 160 to corresponding HTML entities. |
|---|
| 41 | | Selecting 'russian' you switch off the conversion described above and |
|---|
| 42 | | set encoding of mail messages to KOI8-R. Note that Midgard doesn't convert |
|---|
| 43 | | symbols in mail messages to KOI8-R but expects it from client program. |
|---|
| 44 | | |
|---|
| 46 | | To access the Midgard sites you'll need to set up virtual hosts |
|---|
| 47 | | for them. You can use either name-, ip- or port-based virtual hosts. |
|---|
| 48 | | See the Midgard FAQ and Apache documentation for details. |
|---|
| 49 | | |
|---|
| 50 | | To activate the Midgard admin in the address 'localhost/admin' you |
|---|
| 51 | | should set up a virtual host like this one: |
|---|
| 52 | | |
|---|
| 53 | | # httpd.conf |
|---|
| 54 | | <VirtualHost 127.0.0.1> |
|---|
| 55 | | ServerName localhost |
|---|
| 56 | | # Configure text parser: |
|---|
| 57 | | # Change to 'russian' for Russian Midgard |
|---|
| 58 | | MidgardParser latin1 |
|---|
| 59 | | # Configuration for Russian Midgard - we use mod_charset to automate |
|---|
| 60 | | # re-encoding of page and query's data in respect of client's browser |
|---|
| 61 | | <IfModule mod_charset.c> |
|---|
| 62 | | # default charset for real or virtual server (selected if all other charset- |
|---|
| 63 | | # selections methods fails) |
|---|
| 64 | | CharsetDefault koi8-r |
|---|
| 65 | | # Default source (on-disk) charset (we keep all content in DB in KOI8-R |
|---|
| 66 | | # encoding). If you want different charset, please re-encode midgard-ru.sql |
|---|
| 67 | | # before inserting it into DB too. |
|---|
| 68 | | CharsetSourceEnc koi8-r |
|---|
| 69 | | # Force mod_charset to do its work |
|---|
| 70 | | CharsetDisable Off |
|---|
| 71 | | </IfModule> |
|---|
| 72 | | </VirtualHost> |
|---|
| 73 | | |
|---|
| 74 | | Then run the following SQL command to map the Midgard admin site to |
|---|
| 75 | | the virtual host you just created. |
|---|
| 76 | | |
|---|
| 77 | | UPDATE host SET name='localhost',prefix='/admin' WHERE id=1 |
|---|
| 78 | | |
|---|
| 79 | | NOTE: The default administrator username is "admin" and |
|---|
| 80 | | the password is "password". |
|---|
| 81 | | |
|---|
| 82 | | Note that you'll need to use the Midgardized PHP module to correctly |
|---|
| 83 | | parse the Midgard template codes. You shouldn't directly fetch the |
|---|
| 84 | | Midgard root file as it should be read only by mod_midgard module. |
|---|
| 85 | | Do not place the root file inside the Apache document root. |
|---|
| 86 | | |
|---|
| 87 | | ** ADVANCED FEATURES ** |
|---|
| 88 | | |
|---|
| 89 | | Syntax: MidgardPageDatabase [database] [username] [password] |
|---|
| 90 | | Example: MidgardPageDatabase midgardadmin midgard midgard |
|---|
| 91 | | The database to fetch page and style information from. You can use |
|---|
| 92 | | this to partially emulate sitegroups. Pages will be served from this |
|---|
| 93 | | database but the pages will run accessing data from the database |
|---|
| 94 | | specified with the 'MidgardDatabase' directive. You can put shared |
|---|
| 95 | | sites in such a database, and these sites will be available while |
|---|
| 96 | | access to the data in them is totally prohibited. |
|---|
| 97 | | |
|---|
| 98 | | Syntax: MidgardAuthDatabase [database] [username] [password] |
|---|
| 99 | | Example: MidgardAuthDatabase midgardadmin midgard midgard |
|---|
| 100 | | The database to authenticate from. You can use this to arrange access |
|---|
| 101 | | to sites served from databases where you have no Midgard user account. |
|---|
| 102 | | Used in combination with MidgardPageDatabase and MidgardDatabase. |
|---|
| 103 | | Users authenticated from this database will be granted full |
|---|
| 104 | | (root-level) access no matter what. |
|---|
| 105 | | |
|---|
| 106 | | Syntax: MidgardAuth [On|Off] |
|---|
| 107 | | Example: MidgardAuth On |
|---|
| 108 | | Allow authentication against the midgard database for regular apache |
|---|
| 109 | | 'require' protection. |
|---|
| 110 | | |
|---|
| 111 | | Syntax: MidgardTemplate [filename] |
|---|
| 112 | | Example: MidgardTemplate elements.xml |
|---|
| 113 | | Name of the style element files used for filetemplates. |
|---|
| | 28 | You should use tools provided by midgard-data package to configure Virtual Host. |
|---|