proof
13-02-2011 14:46:56
Check it out here!
I decided to port Betajaen's ruby script to PHP because I didn't wanna install ruby, and I already had PHP (always have PHP installed). Usage is the same as the ruby one.
Copy the source into a file named 'ogrexmltoflower.php'.
How to make it work (Windows):
Easiest way to get PHP is to get xampp.
It's your decision on where do you want the converter stored, but I hope you've done it by now. Go to that folder and add another file named ogrexmltoflower.bat, which should contain:
In order to run it from the command line, you have to set some paths. Go to System -> Advanced System Settings -> Advanced -> Environment Variables and under System variables find Path and edit it. At the end, add the following:
where you would replace PATH_TO_XAMPP by the path to XAMPP, logically. The default path is c:\xampp\
Also replace PATH_TO_CONVERTER with the path to your converter.
And that's it!
How to make it work (Linux, Ubuntu):
You also have xampp for linux, so download it.
It's your decision on where do you want the converter stored, but I hope you've done it by now. Go to that folder and add another file named ogrexmltoflower, which should contain:
Open the terminal and do a 'gedit ~/.bashrc', scroll down to the bottom and add: 'export PATH=$PATH:/path/to/converter/:/opt/lampp/bin/'. This is, of course, if your lampp instalation is in /opt/lampp/.
Hope it works fine ^^
I decided to port Betajaen's ruby script to PHP because I didn't wanna install ruby, and I already had PHP (always have PHP installed). Usage is the same as the ruby one.
Copy the source into a file named 'ogrexmltoflower.php'.
How to make it work (Windows):
Easiest way to get PHP is to get xampp.
It's your decision on where do you want the converter stored, but I hope you've done it by now. Go to that folder and add another file named ogrexmltoflower.bat, which should contain:
@echo.
@echo off
SET lib=%~dp0
php -q "%lib%ogrexmltoflower.php" %*
echo.
exit /B %ERRORLEVEL%
In order to run it from the command line, you have to set some paths. Go to System -> Advanced System Settings -> Advanced -> Environment Variables and under System variables find Path and edit it. At the end, add the following:
PATH_TO_XAMPP\php;PATH_TO_CONVERTER\;
where you would replace PATH_TO_XAMPP by the path to XAMPP, logically. The default path is c:\xampp\
Also replace PATH_TO_CONVERTER with the path to your converter.
And that's it!

How to make it work (Linux, Ubuntu):
You also have xampp for linux, so download it.
It's your decision on where do you want the converter stored, but I hope you've done it by now. Go to that folder and add another file named ogrexmltoflower, which should contain:
#!/bin/bash
exec php -q "ogrexmltoflower.php" "$@"
Open the terminal and do a 'gedit ~/.bashrc', scroll down to the bottom and add: 'export PATH=$PATH:/path/to/converter/:/opt/lampp/bin/'. This is, of course, if your lampp instalation is in /opt/lampp/.
Hope it works fine ^^