[pmwiki-users] new to PMWiki

Petko Yotov 5ko at 5ko.fr
Mon May 4 10:52:41 CDT 2015


On 2015-05-04 15:30, Alice Gorman wrote:
> I am new to PMWiki and would like to add a link to execute an AS400 
> .bat
> file.
> Does anyone know if this is possible and if so what the coding would 
> be?

If you want PmWiki to launch/execute a program on the server, search the 
PHP documentation for

   passthru()
   popen()
   exec()
   system()

And see for example how the core uses an external program to merge 
simultaneous edits (scripts/simuledit.php), or how the SysDiff Cookbook 
recipe calls an external program.

If you want visitors of the wiki to download a *.bat file from the 
server and execute it on their computers, simply link the file or upload 
it to the wiki with [[Attach:program.bat]]. To allow uploading of bat 
files see the documentation here (section "Adding new file types to 
permitted uploads"):
   http://www.pmwiki.org/wiki/PmWiki/UploadsAdmin

Petko




More information about the pmwiki-users mailing list