PHP4 and PHP5 on Site5

From the Knowledge Base:

We have two versions of PHP installed on all of our servers. By default, it is PHP version 4.4.1. There is nothing extra to do to use this version.

To use PHP version 5.1.1, you have two choices.

1. Make sure your file ends in .php5

2. Add the following line to your .htaccess file to have all .php files using PHP5.

AddHandler application/x-httpd-php5 .php

Upgrading from Instiki-AR Beta 1 to 0.11.0

So, here’s the plan…

  • Make a full backup.
  • Get the README from the Instiki site
  • Download the latest release from rubyforge:
  • Unpack it to the place on the host where you keep your Ruby on Rails apps.
  • Remove symbolic link with existing Instiki version
  • Put static html in place to warn of upgrade if necessary.
  • Configure config/database.yml as it was before, pointing to the database(s)
  • Configure environment.rb to contain the following before running either ‘rake migrate’ or instiki itself (path in RAILS_ROOT is indicative of where the instiki app dir is actually located):
# The path to the root directory of your application.
RAILS_ROOT = '/home/awebfact/rorapps/instiki-0.11.0/'

ENV['RAILS_ENV'] = "production"
RAILS_ENV = ENV['RAILS_ENV'] || 'development'
  • Also, execute this sql for the instiki database(s) in phpMyAdmin or else on the command line:
create table schema_info (version integer(11));
insert into schema_info (version) values (1);
  • go to instiki directory and do: 
# rake migrate
(in /home/awebfact/rorapps/instiki-0.11.0)
  • Upload images. Upload previous public/dispatch.fcgi that worked!
  • Remove symbolic link with existing Instiki version
  • delete subdomain
  • re-create subdomain
  • delete subdirectory created as a result
  • Link symbolically with new dir: [~/public_html]# rm -rf wiki [~/public_html]# ln -s ~/rorapps/instiki-0.11.0/public ~/public_html/wiki [~/public_html]# ls -lia wiki
3867003 lrwxrwxrwx  1 awebfact awebfact 44 Aug  2 14:40 wiki -> /home/awebfact/rorapps/instiki-0.11.0/public/

Added TinyMCE

After much going back and forth on this, we have opted for the TinyMCE rich text editor option.

We plan to use it in conjunctino with the image and image-assist modules for editors, and alone for regular users.


Keep a small footprint



Let’s add an image to be displayed in the above paragraph, by clicking on the image-assist icon (we haven’t installed the tinymce module plug-in for img_assist.