Quercus: Mediawiki
From Resin 3.0
Steps:
- unpack mediawiki in webapps/wiki
- modify languages/Language.php to work around JDBC mysql driver bug
- add resin-web.xml
- start Resin and browse to http://localhost:8080/wiki
modifications to mediawiki
First, you will need to modify languages/Language.php in the mediawiki distribution. This is to work around a bug in the JDBC driver.
It's important to do this first, because initializing the database with the buggy code will make it very difficult to fix later.
In the Languages.php, you need to remove the \\\' strings, i.e. 3 backslashes followed by a single quote. There are three instances. Two you\\\'re and one can\\\'t.
resin-web.xml
The resin-web.xml needs to add the QuercusServlet and map it to *.php. Optionally, it configures a <database> as PHP's database. Quercus can automatically create database pools if you omit the <database> configuration, but it's better to configure it explicitly.
resin-web.xml
<web-app xmlns="http://caucho.com/ns/resin"> <database jndi-name='jdbc/wiki'> <driver type="com.mysql.jdbc.jdbc2.optional.MysqlConnectionPoolDataSource"> <url>jdbc:mysql://localhost:3306/test_wiki2</url> <user></user> <password></password> </driver> </database> <servlet-mapping url-pattern="*.php" servlet-class="com.caucho.quercus.servlet.QuercusServlet"> <init compile="true" database="jdbc/wiki"/> </servlet-mapping> <welcome-file-list>index.php</welcome-file-list> </web-app>