[pmwiki-users] RichEdit configuration troubles

Russell Bailey russell-pmwiki at saberpunk.net
Thu Sep 22 16:55:03 CDT 2005


Jeremy Sproat wrote:

>Russell,
>
>Saving text doesn't seem to work.
>
>In WikiConverter.php on line 18 there's
>
>   chdir("../cgi-bin/");
>
>...which will break if the cgi-bin/ directory isn't at the same level
>as the pmwiki/ directory.  However, when I changed this to
>
>   chdir($RichEdit_PerlDirectory);
>
>...any page I try to save ends up blank.
>
>I'm trying to figure out where it's breaking.  By all appearances, the
>exec() line in WikiConverter.php is returning 255, and $return_array
>is empty.  Apparently, one of the Perl modules can't find the module
>file "auto/HTML/TreeBuilder/descendents.al" in @INC.  It's possible
>there there is one more Perl module that is needed...or perhaps my
>installation of HTML::Tree is too old.  I'm still looking into this.
>  
>
I'd be interested to know the answer to that.  I don't _think_ it's an 
additional dependency,  but there could be a version issue.

>At any rate, I've been reading through WikiConverterWrapper.pl, and it
>doesn't look like it's actually a cgi script.  It looks like you're
>running it as a command-line script.  In theory, you could run this
>script anywhere in the directory tree, even from within the
>cookbook/richedit/ directory.  You may not need to worry about the
>cgi-bin/ directory at all.
>  
>
Good point.  I didn't think about it,  because it's moot in my web 
environment.

One thing that's occurred to me since the initial implementation is that 
it might be better to push more of the conversion logic into the 
JavaScript,  using XmlHttpRequest to call PmWiki actions that convert 
the wiki markup to HTML after the page load and the HTML to wiki markup 
on submit.

I've also considered reimplementing the WikiConverter in PHP,  but that 
seems like a bit much effort to go to at this point.




More information about the pmwiki-users mailing list