ich habe folgendes Problem mit meiner Pythoninstallation. Wenn ich folgendes Skript aufrufe:
Code: Alles auswählen
#!/usr/local/bin/python
import mapscript
# Set the map file to use
mapfile = "geoland_test.map"
# Create a mapObj, initialized with the mapfile above
mapobject = mapscript.mapObj(mapfile)
# Create an imgObj that has an image of the map
mapimage = mapobject.draw( )
# Save the mapimage to a file
mapimage.save("geoland.png")
erhalte ich folgenden error_log fehler:
hat vielleicht jemand eine Idee wie ich den mapserver für python aktiviere bzw installieren kann?[Fri Dec 07 10:49:12 2007] [error] [client 172.21.18.22] Traceback (most recent call last):
[Fri Dec 07 10:49:12 2007] [error] [client 172.21.18.22] File "/var/www/htdocs/tc/tests/test.py", line 2, in <module>
[Fri Dec 07 10:49:12 2007] [error] [client 172.21.18.22] import mapscript
[Fri Dec 07 10:49:12 2007] [error] [client 172.21.18.22] ImportError: No module named mapscript
[Fri Dec 07 10:49:12 2007] [error] [client 172.21.18.22] Premature end of script headers: test.py
mapserver version 4.10.2 ist auf meinem system installiert.[/quote]