From: <art...@vo...> - 2002-11-09 13:01:23
|
Hi, After testing TWiki, I've just tried PHPwiki 1.3.3 because I found Twiki too complicated to use for my users. I've installed PHPwiki with MySQL but I can only get the first page right ("Loading up Virgin wiki"). If I then click on a link, I get a page full of junk characters. Here's how I installed PHPwiki: 1) Extract cd /home/http/phpwiki/ tar xzf ~/phpwiki-*.tar.gz mkdir -p pages/ chown http http pages/ chmod 0755 pages/ 2) Create the MySQL base db_user=3D"wikiuser" db_passwd=3D"wiki" mysqladmin --user=3Droot --password=3D"sqlpwd" create phpwiki cat <<EOF | mysql --user=3Droot --password=3D"sqlpwd" grant all privileges on *.* to $db_user@localhost \ identified by "$db_passwd" with grant option; flush privileges; EOF mysql --user=3D"$db_user" --password=3D"$db_passwd" phpwiki \ < /home/http/phpwiki/schemas/mysql.sql 3) Update httpd.conf Alias /wiki/ /home/http/phpwiki/ <Directory /home/http/phpwiki> AllowOverride None Order allow,deny Allow from all SSLOptions +StdEnvVars </Directory> 4) Modify index.php Here's the diff from the released index.php to my index.php: @@ -93,7 +93,7 @@ // This is used to generate a keywords meta tag in the HTML templates, // in bookmark titles for any bookmarks made to pages in your wiki, // and during RSS generation for the <title> of the RSS channel. -//define('WIKI_NAME', 'PhpWiki'); +define('WIKI_NAME', 'PhpWiki'); // If set, we will perform reverse dns lookups to try to convert the // users IP number to a host name, even if the http server didn't do @@ -103,8 +103,8 @@ // Username and password of administrator. // Set these to your preferences. For heaven's sake // pick a good password! -define('ADMIN_USER', ""); -define('ADMIN_PASSWD', ""); +define('ADMIN_USER', "root"); +define('ADMIN_PASSWD', "rootpwd"); // If true, only the admin user can make zip dumps, else zip dumps // require no authentication. @@ -138,7 +138,7 @@ // PhpWiki can generate an access_log (in "NCSA combined log" format) // for you. If you want one, define this to the name of the log file. -//define('ACCESS_LOG', '/tmp/wiki_access_log'); +//define('ACCESS_LOG', '/var/log/phpwiki/access_log'); // If ALLOW_BOGO_LOGIN is true, users are allowed to login (with @@ -188,8 +188,8 @@ // $DBParams =3D array( // Select the database type: - //'dbtype' =3D> 'SQL', - 'dbtype' =3D> 'dba', + 'dbtype' =3D> 'SQL', + //'dbtype' =3D> 'dba', // For SQL based backends, specify the database as a DSN // The most general form of a DSN looks like: @@ -202,7 +202,7 @@ // // FIXME: My version Pear::DB seems to be broken enough that there // is no way to connect to a mysql server over a socket right now. - //'dsn' =3D> 'mysql://guest@:/var/lib/mysql/mysql.sock/test', + 'dsn' =3D> 'mysql://wikiuser:wiki@localhost/phpwiki', //'dsn' =3D> 'mysql://guest@localhost/test', //'dsn' =3D> 'pgsql://localhost/test', @@ -217,7 +217,7 @@ //'prefix' =3D> 'phpwiki_', // Used by 'dba' - 'directory' =3D> "/tmp", + 'directory' =3D> "/home/http/phpwiki/pages", 'dba_handler' =3D> 'gdbm', // Either of 'gdbm' or 'db2' work great for me. //'dba_handler' =3D> 'db2', //'dba_handler' =3D> 'db3', // doesn't work at all for me.... @@ -314,7 +314,7 @@ //define('THEME', 'Hawaiian'); //define('THEME', 'MacOSX'); //define('THEME', 'Portland'); -//define('THEME', 'Sidebar'); +define('THEME', 'Sidebar'); //define('THEME', 'SpaceWiki'); // Select a valid charset name to be inserted into the xml/html pages, Did I miss something ? ------------------------------------------ Faites un voeu et puis Voila ! www.voila.fr |
From: Matti A. <ma...@ik...> - 2002-11-09 14:58:19
|
On Saturday 09 November 2002 15:00, arthur.chereau wrote: > After testing TWiki, I've just tried PHPwiki 1.3.3 because I found > Twiki too complicated to use for my users. I've installed PHPwiki > with MySQL but I can only get the first page right ("Loading up > Virgin wiki"). If I then click on a link, I get a page full of junk > characters. Are you using Apache 2.0.x? I am, and I got the same results. The reason apparently is that PhpWiki turns HTTP gzip compression on whether the client supports it or not. To fix it, I commented out the guts of compress_output() in lib/Request.pm. Cheers, m. |
From: Jeff D. <da...@da...> - 2002-11-09 16:32:46
|
> If I then click on a link, I get a page full of junk characters. > > Are you using Apache 2.0.x? I am, and I got the same results. The reason > > apparently is that PhpWiki turns HTTP gzip compression on whether the > client supports it or not. To fix it, I commented out the guts of > compress_output() in lib/Request.pm. Hrmph. Yes this has come up before. I suppose we should make the compression a config option (and probably disable it by default.) It would be nice to figure out what the problem is. AFAIK, PHP should only be compressing the output if the browser sends headers indicating that it can accept it. ("Accept-Encoding: gzip" is the key header I think.) Could it be that output is getting double compressed (once by PHP, once by Apache) in your case? |
From: Aredridel <rs...@nb...> - 2002-11-09 18:56:54
|
On Sat, Nov 09, 2002 at 08:32:39AM -0800, Jeff Dairiki wrote: > > If I then click on a link, I get a page full of junk characters. > > > > Are you using Apache 2.0.x? I am, and I got the same results. The reason > > > > apparently is that PhpWiki turns HTTP gzip compression on whether the > > client supports it or not. To fix it, I commented out the guts of > > compress_output() in lib/Request.pm. > > Hrmph. Yes this has come up before. I suppose we should > make the compression a config option (and probably disable it > by default.) It's a known bug in all but the latest PHP -- the latest ob_gzhandler works as it should. Detecting the PHP version should be easy... Ari |