[pmwiki-users] Standalone observations on GNU/Linux

Petko Yotov 5ko at free.fr
Sat Apr 28 21:04:47 CDT 2007


Hi Patrick and all,

I am absolutely thrilled that I finally managed to start and use the 
standalone version of PmWiki!!! Now I can wiki even if I am lost in a place 
without the tinyest WiFi access... :-))

It is working as a charm for more than 24 hours (under light load), I didn't 
notice slowness on the gui-buttons other users reported. Tested also the 
ThumbList recipe, and it works too (threaded as well as normal modes, and 
this is quite a complex addon, so most other recipes will work too).

As usual, I have some observations and questions :-)

1. [Fixed] On my system there are five php binaries (probably some are links):
 php  php4-cgi  php5  php5-cgi  php-cgi 

And the script only runs well with the "php5-cgi" version. Just "php" is 
actually a kind of php4-cli and it does not work well, even the phpinfo is 
text-only. So I suggest that the call to "php" in HandleWiki() be 
autodetected:

  # Get the current php binary name
  global $_ENV;
  $php_bin = $_ENV["_"];

  function HandleWiki($ClientSocket, $post) {
    global $PmWikiDir, $php_bin; # was: global $PmWikiDir;
    #    was : proc_open("php pmwiki.php", $proc_talk, $pipes);
    $process = proc_open("$php_bin pmwiki.php", $proc_talk, $pipes);
    # [...]

I am ready to write the missing Unix section in the Cookbook, but Patrick can 
you say if the code change is Ok? (Attached is the modified version.)


2. [Not fixed] The wiki does not behave well with browser caching 
$EnableIMSCaching = 1; : if I hit Shift+Reload in the browser (clear the 
browser cache and refresh) and the page was not modified, I get an empty 
blank screen, and then, all other pages get blank. I need to kill the server 
and restart it. This may be not a big problem, but I had copied a config.php 
from elsewhere with caching, so, I am reporting it here. Reverting to the 
standard $EnableIMSCaching = 0; solves the problem.

3. The PmWiki Browser cache-control probably may be added to the server, for 
the HandleFile() function.

4. I wish to have an action HandleExit() that would stop the server. It is 
especially usefull when the process is started in the background. I can write 
it, but do you think it may be usefull to others too?

Thanks,
Petko



-------------- next part --------------
A non-text attachment was scrubbed...
Name: pmwikiserv2.php
Type: application/x-php
Size: 8131 bytes
Desc: not available
Url : /pipermail/pmwiki-users/attachments/20070429/07119e60/attachment.bin 


More information about the pmwiki-users mailing list