Kamoo Mapserver e sebetsang kateng

Nako e fetileng eo re buileng ka eona ka lebaka la hore na ke hobane'ng MapServer le metheo ea ho kenya. Joale a re ke re boneng tse ling tsa ts'ebetso ea eona ka boikoetliso le 'mapa oa likhaba tsa Chiapaneco.

mapserver geoserver Moo o nyolohileng teng

Hang ha Apache e kenyelitsoe, sengoliloeng sa kamehla sa MapServer ke fensetere ea OSGeo4W ka holimo ho C: /

Ka hare, ho na le li-folders tse fapaneng le mekhoa ho latela se kenngoa, empa folda bakeng sa khatiso e tlameha ho kena ka hare ho Apache. Tabeng ena fensetere e bitsoa gis.

  • Joale ka hare, fensetere ea data e na le lihlopha, orthophoto, joalo-joalo.
  • Moleng oa fensetereng, joalo-joalo, ho na le li-fontsane tsa mofuta oa 'nete tse sebelisitsoeng bakeng sa mabitso, ka kakaretso .ttf. Hape mona ke file ea txt e phahamisang bona le e 'ngoe e hlalosang matšoao.
  • 'Me qetellong ka fensetereng ea httdocs e-ea ho maqephe a maqephe a phahamisang tšebeletso.
  • mapserver geoserver

Leqephe la websaete

Mohlala, ke tla sebelisa nyeoe e bontšitsoeng nakong e fetileng. Ha e le hantle e na le faele ea index e khutlisetsang ho e mong oa phtml ho eketsa, 'me hona ho phahamisa mesebetsi e hahiloeng php le limmapa. Fensetere e na le litšoantšo tse amanang le leqephe.

mapserver geoserver

Haeba re sheba, phtml ke feela shell e hahiloeng ho tloha litafole, 'me e bitsoa mesebetsing ea mapscript / php. U lokela ho ema u sebelisa:

http://localhost/gis/gispalenque.phtml

Phello e bontšoa ka tlase:

  • ho bohareng ba mosebetsi GMapDrawMap (),
  • ka ho le letona pitso ea ho ea Kakaretso ea GMapDrawKeyMap (),
  • mohaho o ka tlaase mona GMapDrawScaleBar (),
  • mme ha ho na le mesebetsi ea ho tsamaisa, boemo bo mabapi le lebokose la list haeba (! IsHtmlMode ()) e le "<! -" le liqeto: ZOOM_IN, ZOOM_OUT, RECENTER, QUERY_POINT.

E se e ntse e sebetsa, ponahalo e shebahala tjena:

mapserver geoserver

Lifaele tsa .map

Ho kopanngoa ha khatiso ea Maperver ke seo Apache a se tsosang, se romela php mapscript 'me joale e feta ka khetla eo. Empa boholo ba saense bo ka har'a lifaele tsa .map, tse sa lokelang ho ferekanngoa le tse hlahisoang ke Mapinfo, Lintho tse ngata kapa tsa Mapporo ea Mapolanka ka mokhoa o tšoanang.

Tsena .map ke lifaeletso tsa mongolo, tse nang le 'mapa ka mokhoa oa script. Tsena li ka bōptjoa ka mananeo a lik'homphieutha tse kang Quantum GIS, haeba li behiloe ho e 'ngoe ea' mapa o ka sehloohong, o mong oa Keymap le tse peli bakeng sa wms services wms le wfs. A re ke re boneng kamoo mapolanka a sebetsang kateng:

Mapa

LEQEPHE PALENQUE_DEMO
STATUS ON
SIZE 600 450
SYMBOLSET ../etc/symbols.txt
EXTENT 604299 1933386 610503 1939300 # BOPHELO BA MAPA E MONG A PALENKE
#EXTENT 605786 1935102 608000 1938800 #SOLO SEBISO SE 01
METERS METERS
SHAPEPATH "../data"
TŠEBELETSO HO
IMAGECOLOR 255 255 255
FONTSET ../etc/fonts.txt

  • MAP e bontša hore mongolo o qala
  • STATUS, e bonts'a hore na 'mapa o sa lekanyetsoang o teng kapa che
  • SIZE ke boholo ba pontšo
  • SYMBOLSET e bontsa tsela ea matšoao
  • EXTENT ke likopano tsa pontšo. Letšoao la # le sebelisetsoa ho etsa lipolelo
  • UNITS bakeng sa lihlopha
  • SHAPEPATH, tsela eo lihlopha li leng ho eona
  • Bohle qetellong bo tla fela ka taelo ea END

Ka hare, khoutu e qala ka taelo ea taelo, mme e qetella ka END, mohlala ka bonyane le boholo bo phahameng; litlhaku tsa litšoantšo tsa nakoana:

Web
MINSCALE 2000000
MAXSCALE 50000000

IMAGEPATH "C: \ OSGeo4W / tmp / ms_tmp /"
IMAGEURL "/ ms_tmp /"
QETA

mapserver geoserverSebaka sa tekanyo:

SCALEBAR
IMAGECOLOR 255 255 255
LABEL
COLOR 0 0 0
SIZE SMALL
QETA
SIZE 300 5
COLOR 255 255 255
BACKGROUNDCOLOR 0 0 0
OUTLINECOLOR 0 0 0
Litsi tse UNITS
LITŠOANTŠISO 3
STATUS ON
QETA

mapserver geoserverSetho sa raster: se tsamaeang ka lichelete, ka tlhaloso hothathamong e kang "Ortofoto", ho tswa ho tiff e fumanehang foleng ea data:

LAYER
NAME orthophoto
METADATA
"Tlhaloso" "OrtoFoto"
QETA
TYPE RASTER
STATUS OFF
DATA "C: \ OSGeo4W / apps / gis / data / ortofotoGral.tif"
#OFFSITE 0 0 0
QETA

Shp layer ea polygone, e thehiloeng ho latela litekanyetso, ho hlahisa boitsebiso bo itseng ka html template, e nang le sans font font, boholo ba 6, mmala o motšo le bophahamo bo mosoeu ba mongobo oa 5 ...

mapserver geoserver

LAYER
LEGO sekhahla02Zone
TYPE POLYGON
STATUS OFF
TRANSPARENCY 50
EXTENT 607852 1935706 610804 1938807 METADATA
"Tlhaloso" "Tlhaloso ea Boleng ba Bohlokoa 02"
"RESULT_FIELDS" "MsLink Cve_Mz Cve_Pred prop Area Perimeter VALUE"
QETA
DATA PALENQUE_SECTOR01
TEMPLATE "ttt_query.html"
TOLERANCE 5
# TOLERANCEUNITS PIXELS
LABELITEM "VALOR"
CLASSITEM "VALOR"
LABELCACHE ON
CLASS
SYMBOL 1
COLOR 128 128 128
OUTLINECOLOR 0 0 0
NAME "ZoneNULL"
EXPRESSION ([VALUE] = 0)
LABEL
ANGLE AUTO
COLOR 0 0 0
E FETILENG FETA
TYPE TRUETYPE
POSITION cc

BATHO BA SEBELETSENG SEBELE
BUFFER 5
SIZE 6
OUTLINECOLOR 200 200 200
QETA
Qetellong # koro ea bohlokoa 0
CLASS
SYMBOL 3
COLOR 255 128 128
#COLOR -1 -1 -1 #SIN FILLING

... joalo-joalo ho fihlela ho koaloa

QETA
Qetellong # Nako ea Bohlokoa
Qetellong # Lera

Ho etsa qeto

Kahoo, ho sebetsa ka MapServer, le hoja e bonolo, ho ba le mokhoa o rarahaneng oa ho le e fokolang haholo bakeng sa sri lanka jobs kholo hobane tsohle e .map ena. The bozangi litomba kholo ka ho fetisisa ke hore lintho tsohle se etsoa ka maoto, tse kang hlalosang e mong le e 'mala o ka theming ka,' me ka hona ho hlaha lisebelisoa joaloka CartoWeb, ho sebetsa ka MapServer empa tlisa plugins a haha ​​le mehlala likarolo tse etsang hore phetolelo ena ea khale ba ho lula e le ho bala pele:

  • Sebelisa liforeimi tse fapaneng, le AJAX e le hore u li khatholle ka bomong
  • Fana ka khoutu, e fane ka script e ngolang hape .map ho latela melao ea bohlokoa
  • Matla a khutlisetsa ho falla ho sa hlokahale ho khatholoha, joalokaha eka e ne e le lera
  • Phatlalatso ea lipapali tsa Inthaneteng, ho ngola hang-hang ka cache
  • Kenya lera ka mokhoa oa vector
  • Fetisa ho Google Earth
  • Hlahisa PDF ea ho tsamaisoa

Ka le hlahlamang re tla sheba CartoWeb, bonang! Ke tlohela ho hokahanya mehlala e ka sehloohong.

3 Likarabo ho "Kamoo Mapserver e sebetsang kateng"

  1. Lumela,

    Ke leka ho bitsa lera ho tswa ho .map, ka tsela e latelang:

    LAYER
    Mabitso a li-NAME
    THAHA POTSO
    PONTS'ELE OGR
    KHONO # 2: virtual.ovf »
    »

    xxxxx
    EXEC ......
    eess_id
    wkbPoint
    WGS84

    »

    Bothata ba ka ke hore ts'ebeletso ea DSN e fana ka mathata: ha ke kopa mokhoa oa GetCapility ke khutlisa password ea database ... na nka kenya mohala faeleng ho qoba "ho fana" phasewete kapa na ke phoso ea DSN ???? Kea leboha!

  2. MapServer ke morero o tummeng oa Open Source eo morero oa oona e leng ho bontša limmapa tse potlakileng tsa marang-rang ho Internet. Koloi e tsamaisitsoeng ke koloi e ngotsoeng ho folda e se nang letho ka molumo o sebelisang tsamaiso ea faele ea NTFS. Li-drive tse tsamaeang li sebetsa joaloka tse ling tse khanna, empa li fuoa litsela tsa koloi ho e-na le litlhaku tsa koloi.

Tlohela karabo

aterese ya hao ya imeile ke ke ho phatlalatswa.

Sebaka sena se sebelisa Akismet ho fokotsa spam. Ithute kamoo litlhaloso tsa hau li hlahang kateng.