Sorry, maybe I didn't explain myself well because actually, I don't get any error from the php web page, simply the code related to grass is not executed.For instance gsetup.init(gisbase, gisdb, location, mapset) does not create any file in my /tmp/ folder and the print(gscript.gisenv()) is not printed. I checked the import of the grass libraries (print(sys.modules)) and they seem to be correctly imported. ________________________________ Da: Moritz Lennert <[email protected]> Inviato: lunedì 28 settembre 2020 17:29 A: roberta fagandini <[email protected]>; [email protected] <[email protected]> Oggetto: Re: [GRASS-user] exwcuting grass python script from php web page
On 28/09/20 12:10, roberta fagandini wrote: > Hi all! > I wrote a python script with grass to be run from a php web page. > The python script works perfectly if I run it from the terminal but when > I try to run it from the php web page, the grass related part seems to > be ignored and the grass session is not launched. I set the grass gis > environment following this link [0]. > From the php side, I try to launch the python script using both exec(), > system() and also a bash script to run the python script but I always > got the same error. Maybe you could tell us what error you get ? Moritz
_______________________________________________ grass-user mailing list [email protected] https://lists.osgeo.org/mailman/listinfo/grass-user
