pmapper-users Mailing List for p.mapper (Page 189)
Brought to you by:
arminburger
You can subscribe to this list here.
2006 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(41) |
Nov
(124) |
Dec
(80) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2007 |
Jan
(56) |
Feb
(51) |
Mar
(155) |
Apr
(58) |
May
(67) |
Jun
(83) |
Jul
(76) |
Aug
(32) |
Sep
(58) |
Oct
(113) |
Nov
(63) |
Dec
(83) |
2008 |
Jan
(31) |
Feb
(34) |
Mar
(69) |
Apr
(30) |
May
(87) |
Jun
(64) |
Jul
(47) |
Aug
(18) |
Sep
(35) |
Oct
(53) |
Nov
(37) |
Dec
(31) |
2009 |
Jan
(23) |
Feb
(40) |
Mar
(65) |
Apr
(54) |
May
(92) |
Jun
(55) |
Jul
(87) |
Aug
(27) |
Sep
(81) |
Oct
(32) |
Nov
(77) |
Dec
(51) |
2010 |
Jan
(44) |
Feb
(59) |
Mar
(77) |
Apr
(54) |
May
(36) |
Jun
(36) |
Jul
(52) |
Aug
(62) |
Sep
(68) |
Oct
(58) |
Nov
(72) |
Dec
(27) |
2011 |
Jan
(15) |
Feb
(42) |
Mar
(37) |
Apr
(55) |
May
(84) |
Jun
(27) |
Jul
(27) |
Aug
(42) |
Sep
(42) |
Oct
(18) |
Nov
(83) |
Dec
(71) |
2012 |
Jan
(50) |
Feb
(75) |
Mar
(79) |
Apr
(43) |
May
(18) |
Jun
(22) |
Jul
(20) |
Aug
(13) |
Sep
(26) |
Oct
(30) |
Nov
(21) |
Dec
(30) |
2013 |
Jan
(57) |
Feb
(63) |
Mar
(53) |
Apr
(40) |
May
(39) |
Jun
(16) |
Jul
(43) |
Aug
(16) |
Sep
(37) |
Oct
(64) |
Nov
(31) |
Dec
(7) |
2014 |
Jan
(14) |
Feb
(6) |
Mar
(2) |
Apr
(9) |
May
(1) |
Jun
(18) |
Jul
(95) |
Aug
(6) |
Sep
(25) |
Oct
(33) |
Nov
(29) |
Dec
(30) |
2015 |
Jan
(16) |
Feb
(3) |
Mar
(4) |
Apr
(9) |
May
(19) |
Jun
|
Jul
(11) |
Aug
(3) |
Sep
(9) |
Oct
(11) |
Nov
(4) |
Dec
(9) |
2016 |
Jan
(21) |
Feb
(9) |
Mar
(6) |
Apr
(13) |
May
(21) |
Jun
(4) |
Jul
(3) |
Aug
(2) |
Sep
|
Oct
|
Nov
|
Dec
(1) |
2017 |
Jan
(1) |
Feb
(4) |
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
(1) |
Aug
|
Sep
(1) |
Oct
|
Nov
(1) |
Dec
|
2018 |
Jan
(3) |
Feb
(4) |
Mar
|
Apr
|
May
|
Jun
|
Jul
(2) |
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2019 |
Jan
|
Feb
(1) |
Mar
(1) |
Apr
(3) |
May
(1) |
Jun
|
Jul
|
Aug
(2) |
Sep
|
Oct
|
Nov
|
Dec
|
2020 |
Jan
(1) |
Feb
(1) |
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Eric A. <eri...@bo...> - 2006-12-06 19:42:47
|
Armin, I just click on the zoom cursor, and start dragging it. It starts moving = and hangs. No JS Error. If I click on the cursor, it refreshes the map at = the right zoomed scale. I can move the cursor like this... It's just not = fluid! It might be a configuration of my IE7? -Eric =20 -----Message d'origine----- De=A0: Armin Burger [mailto:arm...@gm...]=20 Envoy=E9=A0: 6 d=E9cembre 2006 13:48 =C0=A0: Eric Allard Cc=A0: pma...@li... Objet=A0: Re: [pmapper-users] Problems with IE7 - Pmapper 1.9.5 - Slider Eric could you maybe provide some more description what the problem is, the=20 JS error and maybe some screenshots? A first fast test with IE 7 worked=20 fine for me, also with the slider, without any errors. The page just=20 loads even slower than with IE 6 and the speed of the DOM implementation = in general seems to be even worse than with IE 6 (that was already=20 incredibly slower than Firefox)... armin=20 =20 =20 =20 =20 =20 =20 =20 =20 =20 =20 =20 =20 =20 =20 =20 =20 Eric Allard wrote: >=20 > Hi! >=20 > I have the same problem with the latest version of Pmapper > (http://www.pmapper.net/download.shtml) >=20 > All other tools seems to be working fine! A lot of people are moving = to IE7! > And I'm sure it's not a big fix to get it to work... I'll try to debug = it! > Any help is appreciated! > Cheers, > -Eric >=20 > -----Message d'origine----- > De : pma...@li... > [mailto:pma...@li...] De la part de = Eric > Allard > Envoy=E9 : 6 d=E9cembre 2006 09:31 > =C0 : pma...@li... > Objet : [pmapper-users] Problems with IE7 - Pmapper 1.9.5 - Slider >=20 > Hi All! > I have some problems with IE7 and the slider of Pmapper 1.9.5. > Anybody has seen this?=20 > -Eric >=20 --=20 Internal Virus Database is out-of-date. Checked by AVG Free Edition. Version: 7.1.409 / Virus Database: 268.14.17/553 - Release Date: = 2006-11-27 =20 --=20 Internal Virus Database is out-of-date. Checked by AVG Free Edition. Version: 7.1.409 / Virus Database: 268.14.17/553 - Release Date: = 2006-11-27 =20 |
From: Armin B. <arm...@gm...> - 2006-12-06 18:47:53
|
Eric could you maybe provide some more description what the problem is, the=20 JS error and maybe some screenshots? A first fast test with IE 7 worked=20 fine for me, also with the slider, without any errors. The page just=20 loads even slower than with IE 6 and the speed of the DOM implementation=20 in general seems to be even worse than with IE 6 (that was already=20 incredibly slower than Firefox)... armin=20 =20 =20 =20 =20 =20 =20 =20 =20 =20 =20 =20 =20 =20 =20 =20 =20 Eric Allard wrote: >=20 > Hi! >=20 > I have the same problem with the latest version of Pmapper > (http://www.pmapper.net/download.shtml) >=20 > All other tools seems to be working fine! A lot of people are moving to= IE7! > And I'm sure it's not a big fix to get it to work... I'll try to debug = it! > Any help is appreciated! > Cheers, > -Eric >=20 > -----Message d'origine----- > De : pma...@li... > [mailto:pma...@li...] De la part de Eric > Allard > Envoy=E9 : 6 d=E9cembre 2006 09:31 > =C0 : pma...@li... > Objet : [pmapper-users] Problems with IE7 - Pmapper 1.9.5 - Slider >=20 > Hi All! > I have some problems with IE7 and the slider of Pmapper 1.9.5. > Anybody has seen this?=20 > -Eric >=20 |
From: Eric A. <eri...@bo...> - 2006-12-06 18:22:47
|
Hi! I have the same problem with the latest version of Pmapper (http://www.pmapper.net/download.shtml) All other tools seems to be working fine! A lot of people are moving to = IE7! And I'm sure it's not a big fix to get it to work... I'll try to debug = it! Any help is appreciated! Cheers, -Eric -----Message d'origine----- De=A0: pma...@li... [mailto:pma...@li...] De la part de Eric Allard Envoy=E9=A0: 6 d=E9cembre 2006 09:31 =C0=A0: pma...@li... Objet=A0: [pmapper-users] Problems with IE7 - Pmapper 1.9.5 - Slider Hi All! I have some problems with IE7 and the slider of Pmapper 1.9.5. Anybody has seen this?=20 -Eric --=20 Internal Virus Database is out-of-date. Checked by AVG Free Edition. Version: 7.1.409 / Virus Database: 268.14.17/553 - Release Date: = 2006-11-27 =20 -------------------------------------------------------------------------= Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share = your opinions on IT & business topics through brief surveys - and earn cash http://www.techsay.com/default.php?page=3Djoin.php&p=3Dsourceforge&CID=3D= DEVDEV _______________________________________________ pmapper-users mailing list pma...@li... https://lists.sourceforge.net/lists/listinfo/pmapper-users --=20 Internal Virus Database is out-of-date. Checked by AVG Free Edition. Version: 7.1.409 / Virus Database: 268.14.17/553 - Release Date: = 2006-11-27 =20 --=20 Internal Virus Database is out-of-date. Checked by AVG Free Edition. Version: 7.1.409 / Virus Database: 268.14.17/553 - Release Date: = 2006-11-27 =20 |
From: Eric A. <eri...@bo...> - 2006-12-06 14:36:09
|
Hi All! I have some problems with IE7 and the slider of Pmapper 1.9.5. Anybody has seen this? -Eric -- Internal Virus Database is out-of-date. Checked by AVG Free Edition. Version: 7.1.409 / Virus Database: 268.14.17/553 - Release Date: 2006-11-27 |
From: Armin B. <arm...@gm...> - 2006-12-06 13:29:38
|
you need to check what image it is, I guess the overview image. You need it either as JPEG or try to set for the OUTPUTFORMAT for png INTERLACE OFF. armin > > Hello List, > I try to get a pdf-print with pmapper3.0 > but I always get the error: > FPDF error: Interlacing not supported: > C:/Programme/Apachegroup/Apache/htdocs/tmp/bfe7b327efb0e2af25d999907c7a1db21165410724007642000.png > > If I try it with pmapper2.1 nothing happens at all. > Do I need to install a special library for that? > > Thank you in advance, Kai > > -- > Dipl.-Geogr. Kai Behncke > > Institut für Geoinformatik und Fernerkundung (IGF) > Universität Osnabrück > Kolpingstr. 7 > 49074 Osnabrück > > Raum: 01/308 > Tel.: +49 541 969-4450 > E-Mail: mailto:kbe...@ig... > Web: http://www.igf.uni-osnabrueck.de > > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share > your > opinions on IT & business topics through brief surveys - and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > pmapper-users mailing list > pma...@li... > https://lists.sourceforge.net/lists/listinfo/pmapper-users -- "Ein Herz für Kinder" - Ihre Spende hilft! Aktion: www.deutschlandsegelt.de Unser Dankeschön: Ihr Name auf dem Segel der 1. deutschen America's Cup-Yacht! |
From: Alessandro P. <al...@ti...> - 2006-12-06 13:28:13
|
Il 14:08, mercoled=EC 6 dicembre 2006, Kai Behncke ha scritto: > Hello List, > I try to get a pdf-print with pmapper3.0 > but I always get the error: > FPDF error: Interlacing not supported: > C:/Programme/Apachegroup/Apache/htdocs/tmp/bfe7b327efb0e2af25d999907c7a1d= b2 >1165410724007642000.png > > If I try it with pmapper2.1 nothing happens at all. > Do I need to install a special library for that? just put ITERLACE=3DOFF in mapfile like this: OUTPUTFORMAT NAME png DRIVER "GD/PNG" MIMETYPE "image/png" IMAGEMODE RGB #IMAGEMODE PC256 EXTENSION "png" FORMATOPTION "INTERLACE=3DOFF" END =2D-=20 Alessandro Pasotti itOpen - "Open Solutions for the Net Age" w3: www.itopen.it Linux User# 167502 |
From: Kai B. <kbe...@ig...> - 2006-12-06 13:07:46
|
Hello List, I try to get a pdf-print with pmapper3.0 but I always get the error: FPDF error: Interlacing not supported: C:/Programme/Apachegroup/Apache/htdocs/tmp/bfe7b327efb0e2af25d999907c7a1d= b21165410724007642000.png If I try it with pmapper2.1 nothing happens at all. Do I need to install a special library for that? Thank you in advance, Kai -- Dipl.-Geogr. Kai Behncke Institut f=FCr Geoinformatik und Fernerkundung (IGF) Universit=E4t Osnabr=FCck Kolpingstr. 7 49074 Osnabr=FCck Raum: 01/308 Tel.: +49 541 969-4450 E-Mail: mailto:kbe...@ig...=20 Web: http://www.igf.uni-osnabrueck.de |
From: Armin B. <arm...@gm...> - 2006-12-06 10:28:06
|
maybe have a look at http://svn.pmapper.net/trac/wiki/FaqDebugging armin > Hi armin, Hi list > > I have Pmapper > > > > I setting Php/Mapscript, now work Right you know > > > > But my problem is when load Loyiut of pmapper, Not to appear map, just > image gif "Downloading" nothing more.... > > Legend load rigth, to appear cordinate , is ok > > Scale load ok > > But map not load > I hope you help me > > Thanx > > _________________________________________________________________ > Latinos en EE.UU: noticias y artículos de interés para ti > http://latino.msn.com/noticias/latinoseneeuu > > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share > your > opinions on IT & business topics through brief surveys - and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > pmapper-users mailing list > pma...@li... > https://lists.sourceforge.net/lists/listinfo/pmapper-users -- "Ein Herz für Kinder" - Ihre Spende hilft! Aktion: www.deutschlandsegelt.de Unser Dankeschön: Ihr Name auf dem Segel der 1. deutschen America's Cup-Yacht! |
From: stirner m. <sti...@ho...> - 2006-12-06 01:56:31
|
Hi armin, Hi list I have Pmapper I setting Php/Mapscript, now work Right you know But my problem is when load Loyiut of pmapper, Not to appear map, just image gif "Downloading" nothing more.... Legend load rigth, to appear cordinate , is ok Scale load ok But map not load I hope you help me Thanx _________________________________________________________________ Latinos en EE.UU: noticias y artículos de interés para ti http://latino.msn.com/noticias/latinoseneeuu |
From: Armin B. <arm...@gm...> - 2006-12-05 18:33:41
|
the same function that is defined as the onlick event for refresh map. armin Chris Beaart wrote: > I have created a new tool. After running this tool, I want to refresh > (reload) the map automatically just like pressing the "Refresh Map" button. > Which code do I have to use in the code below to refresh the map. > > > > Thanks, > Chris Beaart. > > > > <?php > > require_once ("C:/ms4w/Apache/php/PEAR/DB.php"); > > session_start(); > > require_once("common.php"); > > > > function DB_addPoint($imgxy, $soort, $waarneming, $datum) > > { > > $db_host = "localhost"; > > $db_type = "mysql"; > > $db_name = "dop"; > > $db_user = "root"; > > $db_pwd = "password"; > > > > $dsn = "$db_type://$db_user:$db_pwd@$db_host/$db_name"; > > #error_log ($dsn); > > #mysql://root:trashcan@localhost/dop > > > > // CONVERT PIXEL X/Y TO MAP UNITS > > $imgxy_arr = explode(" ", $imgxy); > > $x_pix = $imgxy_arr[0]; > > $y_pix = $imgxy_arr[1]; > > $GEOEXT = $_SESSION["GEOEXT"]; > > $geoDeltaX = $GEOEXT["maxx"] - $GEOEXT["minx"]; > > $geoDeltaY = $GEOEXT["maxy"] - $GEOEXT["miny"]; > > $mapW = $_SESSION["mapwidth"]; > > $mapH = $_SESSION["mapheight"]; > > $x_geo = round($GEOEXT["minx"] + (($x_pix/$mapW)*$geoDeltaX)); > > $y_geo = round($GEOEXT["maxy"] - (($y_pix/$mapH)*$geoDeltaY)); > > > > // CONNECT TO DB AND RUN QUERY > > //$geometry = "GeomFromText('POINT($x_geo $y_geo)',26591)"; > > $sql = "INSERT INTO waarnemingen(x,y,soort,waarneming,datum) > VALUES($x_geo,$y_geo,'$soort','$waarneming','$datum')"; > > #error_log ($sql); > > > > $dbh = dbConnect($dsn); > > $result = $dbh->query($sql); > > > > #Closing the current form > > ?> > > <script language=JavaScript> > > window.close(); > > </script> > > <? > > > > #CODE TO REFRESH MAP > > > > if (DB::isError($result)) { > > error_log($result->getDebugInfo()); > > } > > > > // Check that $result is not an error > > if (DB::isError($result)) { > > $dbh->disconnect(); > > return ($result->getMessage()); > > } else { > > $dbh->disconnect(); > > return 1; > > } > > } > > > > function dbConnect($dsn) > > { > > $dbh = DB::connect($dsn); > > > > if (DB::isError($dbh)) { > > error_log($dbh->getDebugInfo()); > > } > > > > if (DB::isError($dbh)) { > > die ($dbh->getMessage()); > > return NULL; > > } else { > > return $dbh; > > } > > } > > > > ?> > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys - and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > pmapper-users mailing list > pma...@li... > https://lists.sourceforge.net/lists/listinfo/pmapper-users > |
From: Chris B. <be...@wi...> - 2006-12-05 17:42:59
|
How can I configure pMapper 3 to Show Legend in stead of Layers by default? Now I always have to click on "Show Legend". Thanks, Chris Beaart. |
From: Marino F. <mar...@gm...> - 2006-12-05 16:13:05
|
I have tried to use the new version of pmapper 3.0.0 released at 03/12, with the same settings of previous version, but the initialization of application failed with this error: Parse error: parse error, unexpected T_OBJECT_OPERATOR in C:\ms4w\apps\pmapper-3.0.0\incphp\init\initmap.php on line 171 Inside the initmap.php i see some change: new code: ... 171 if (!$this->map->getLayerByName($ml)->group) { ... previous version code: ... 171 if (!$ml->group) { ... which is a problem? thanks! Marino |
From: Chris B. <be...@wi...> - 2006-12-05 15:49:29
|
I have created a new tool. After running this tool, I want to refresh (reload) the map automatically just like pressing the "Refresh Map" button. Which code do I have to use in the code below to refresh the map. Thanks, Chris Beaart. <?php require_once ("C:/ms4w/Apache/php/PEAR/DB.php"); session_start(); require_once("common.php"); function DB_addPoint($imgxy, $soort, $waarneming, $datum) { $db_host = "localhost"; $db_type = "mysql"; $db_name = "dop"; $db_user = "root"; $db_pwd = "password"; $dsn = "$db_type://$db_user:$db_pwd@$db_host/$db_name"; #error_log ($dsn); #mysql://root:trashcan@localhost/dop // CONVERT PIXEL X/Y TO MAP UNITS $imgxy_arr = explode(" ", $imgxy); $x_pix = $imgxy_arr[0]; $y_pix = $imgxy_arr[1]; $GEOEXT = $_SESSION["GEOEXT"]; $geoDeltaX = $GEOEXT["maxx"] - $GEOEXT["minx"]; $geoDeltaY = $GEOEXT["maxy"] - $GEOEXT["miny"]; $mapW = $_SESSION["mapwidth"]; $mapH = $_SESSION["mapheight"]; $x_geo = round($GEOEXT["minx"] + (($x_pix/$mapW)*$geoDeltaX)); $y_geo = round($GEOEXT["maxy"] - (($y_pix/$mapH)*$geoDeltaY)); // CONNECT TO DB AND RUN QUERY //$geometry = "GeomFromText('POINT($x_geo $y_geo)',26591)"; $sql = "INSERT INTO waarnemingen(x,y,soort,waarneming,datum) VALUES($x_geo,$y_geo,'$soort','$waarneming','$datum')"; #error_log ($sql); $dbh = dbConnect($dsn); $result = $dbh->query($sql); #Closing the current form ?> <script language=JavaScript> window.close(); </script> <? #CODE TO REFRESH MAP if (DB::isError($result)) { error_log($result->getDebugInfo()); } // Check that $result is not an error if (DB::isError($result)) { $dbh->disconnect(); return ($result->getMessage()); } else { $dbh->disconnect(); return 1; } } function dbConnect($dsn) { $dbh = DB::connect($dsn); if (DB::isError($dbh)) { error_log($dbh->getDebugInfo()); } if (DB::isError($dbh)) { die ($dbh->getMessage()); return NULL; } else { return $dbh; } } ?> |
From: Armin B. <arm...@gm...> - 2006-12-05 12:47:42
|
I probably forgot to add all indexes into an array when modifying the code to cover the extent of all features with the same search id. I'll put it in the svn. thanks armin PS: with regard to bug reports: please try to use the ticket system at http://svn.pmapper.net/trac/report instead of the tracking system of Sourceforge that drives me crazy when using it. You will have to create an account and log in in order to see the 'Create Ticket' link. If this works fine as expected I will again disable the SF trackers. armin -------- Original-Nachricht -------- Datum: Tue, 5 Dec 2006 10:11:44 +0100 Von: Alessandro Pasotti <al...@ti...> An: pma...@li... Betreff: [pmapper-users] Highlight complex features > Hello, sorry for the long post. > > I'm using pmapper 3. > > I have a layer which is a result of a M2M relationship, this means that a > single feature is a result of multiple segments, and the id of the feature > is > unique while the id of single segments can be shared among several > features. > > Everything works fine (more or less) but I found (a bug?) that highlight > shows > only the last segment of the result set. > > To make it work I had to change the initmap.php so that instead of the > last > segment, *all* the single segments are added to the session highlight var > (see "ABP:" comments in the code). > > Basically, the for loop checks all results but only the id of the last is > stored in the session variable (which is an array anyway). > > Should I file a bug for this or is it intentional ? > > > /** > * FUNCTION TO RETURN URL FOR MAPFRAME > * used for starting application with pre-defined extent > * extent read from shape features > */ > function getMapInitURL($map, $zoomLayer, $zoomQuery) > { > $qLayer = $this->map->getLayerByName($zoomLayer); > > // Query parameters > $queryList = split('@', $zoomQuery); > $queryField = $queryList[0]; > $queryFieldType = $queryList[1]; > //$queryValue = "/^" . $queryList[2] ."$/"; > $queryValue = $queryList[2]; > $highlFeature = $queryList[3]; > $setMaxExtent = $queryList[4]; > > // Modify filter for PostGIS & Oracle layers > if ($qLayer->connectiontype == 6 || $qLayer->connectiontype == 8) > { > $q = $queryFieldType == 1 ? "'" : ""; > #$queryValue = "$queryField = $q$queryValue$q"; > //error_log($queryValue); > $queryValue = $queryField . ' ~* \'' . $queryValue .'\' '; > } else { // Shapefile > } > > // Query layer ABP: fix mapscript 410 > // (this is not related with highlight) > $qLayer->queryByAttributes($queryField, "\"$queryValue\"", > MS_MULTIPLE); > $numResults = $qLayer->getNumResults(); > $qLayer->open(); > > // Return query results (SINGLE FEATURE): shape index and feature > extent > /* > $qRes = $qLayer->getResult(0); > $qShape = $qLayer->getShape($qRes->tileindex,$qRes->shapeindex); > $qShpIdx = $qShape->index; > $qShpBounds = $qShape->bounds; > */ > > // Check if layer has different projection than map > // if yes, re-project extent from layer to map projection > $mapProjStr = $this->map->getProjection(); > $qLayerProjStr = $qLayer->getProjection(); > if ($mapProjStr && $qLayerProjStr && $mapProjStr != > $qLayerProjStr) { > $mapProjObj = ms_newprojectionobj($mapProjStr); > $qLayerProjObj = ms_newprojectionobj($qLayerProjStr); > //$qShpBounds->project($this->qLayerProjObj, > $this->mapProjObj); > $reprojectShape = 1; > } > > > // initial max/min values > $mExtMinx = 999999999; > $mExtMiny = 999999999; > $mExtMaxx = -999999999; > $mExtMaxy = -999999999; > > // ABP: Store all shape indexes > $qShpIdxArray = array(); > > // Return query results: shape index and feature extent > for ($iRes=0; $iRes < $numResults; $iRes++) { > $qRes = $qLayer->getResult($iRes); > $qShape = > $qLayer->getShape($qRes->tileindex,$qRes->shapeindex); > $qShpIdx = $qShape->index; > // ABP: Store all segments > $qShpIdxArray[] = $qShpIdx; > $qShpBounds = $qShape->bounds; > if ($reprojectShape) { > $qShpBounds->project($qLayerProjObj, $mapProjObj); > } > > $shpMinx = $qShpBounds->minx; > $shpMiny = $qShpBounds->miny; > $shpMaxx = $qShpBounds->maxx; > $shpMaxy = $qShpBounds->maxy; > > // Get max/min values of ALL features > $mExtMinx = min($mExtMinx, $shpMinx); > $mExtMiny = min($mExtMiny, $shpMiny); > $mExtMaxx = max($mExtMaxx, $shpMaxx); > $mExtMaxy = max($mExtMaxy, $shpMaxy); > } > //die(); > > // Apply buffer (in units of features) > //$buffer = 20000; // <<<<<<<<<<<<<<<<<<<<<< ADAPT VALUE > <<<<<<<<<<<<<<<<< > // ABP: set buffer for points > // (this is not related with highlight) > if ($this->qLayerType == 0) { > $buffer = $_SESSION["pointBuffer"]; > } else { > $buffer = 0.05 * ((($mExtMaxx - $mExtMinx) + ($mExtMaxy - > $mExtMiny)) / 2); > } > // Set buffer for point layers > $mExtMinx -= $buffer; > $mExtMiny -= $buffer; > $mExtMaxx += $buffer; > $mExtMaxy += $buffer; > > > $roundFact = ($map->units != 5 ? 0 : 6); > $shpMinx = round($mExtMinx, $roundFact); > $shpMiny = round($mExtMiny, $roundFact); > $shpMaxx = round($mExtMaxx, $roundFact); > $shpMaxy = round($mExtMaxy, $roundFact); > > $ext = array ($shpMinx, $shpMiny, $shpMaxx, $shpMaxy); > $_SESSION['zoom_extparams'] = $ext; > > > // Set Max Extent for map > if ($setMaxExtent) { > $mapMaxExt['minx'] = $shpMinx; > $mapMaxExt['miny'] = $shpMiny; > $mapMaxExt['maxx'] = $shpMaxx; > $mapMaxExt['maxy'] = $shpMaxy; > > $_SESSION['mapMaxExt'] = $mapMaxExt; > } > > // Add highlight feature if defined in URL parameters > if ($highlFeature) { > // ABP: add all shapes > // $resultlayers[$zoomLayer] = array($qShpIdx); > $resultlayers[$zoomLayer] = $qShpIdxArray; > $_SESSION["resultlayers"] = $resultlayers; > } > > > // Return URL > $searchString = "&mode=map&zoom_type=zoomextent&extent=" . > $shpMinx ."+". $shpMiny ."+". $shpMaxx ."+". $shpMaxy . > ($highlFeature ? "&resultlayer=$zoomLayer+$qShpIdx" : ""); > $mapInitURL = "map.phtml?$searchString"; > > return $mapInitURL; > } > > > -- > Alessandro Pasotti > itOpen - "Open Solutions for the Net Age" > w3: www.itopen.it > Linux User# 167502 > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share > your > opinions on IT & business topics through brief surveys - and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > pmapper-users mailing list > pma...@li... > https://lists.sourceforge.net/lists/listinfo/pmapper-users -- Der GMX SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen! Ideal für Modem und ISDN: http://www.gmx.net/de/go/smartsurfer |
From: Armin B. <arm...@gm...> - 2006-12-05 12:30:27
|
so you have to check why the dll cannot be loaded. This is a Mapserver/Mapscript question and you will find more help on the list there. armin -------- Original-Nachricht -------- Datum: Tue, 05 Dec 2006 03:50:14 +0000 Von: "stirner mathematic" <sti...@ho...> An: pma...@li... Betreff: [pmapper-users] Problem with pmapper 3 > Hi List, Hi Armin > > > Armin, I have pmapper 3, i have an problems > > 1.. when written http://localhost/pmapper3/index.html I see > index.html > default, this is ok. rigth.. > and later i click in (I just work with demodata in pmapper3) > > Small, layer flat view, English-------- The layout to appear, but map I > don't watch -----I just watch gif of Downloading nothing more.. > > > 2 when written http://localhost/pmapper3/index.html I see index.html > default, this is ok, but clikc in 2ª option : > > Medium, layer tree view, German------- to appear the following error: > > Warning: dl() [function.dl]: Unable to load dynamic library > '/ms4w/Apache/php/ext/php_mapscript_48.dll' - No se puede encontrar el > m�dulo especificado. in > C:\ms4w\Apache\htdocs\pmapper3\incphp\globals.php on line 49 > > Fatal error: Call to undefined function ms_newMapObj() in > C:\ms4w\Apache\htdocs\pmapper3\incphp\globals.php on line 58 > > > > I say in config msversion= 48.... > > I don't understanding why to appear that error....... > > > Armin you can healp me please...I sorry my Bad English > Thanx all > > _________________________________________________________________ > Visita MSN Latino Entretenimiento: ¡música, cine, chismes, TV y más...! > http://latino.msn.com/entretenimiento/ > > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share > your > opinions on IT & business topics through brief surveys - and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > pmapper-users mailing list > pma...@li... > https://lists.sourceforge.net/lists/listinfo/pmapper-users -- "Ein Herz für Kinder" - Ihre Spende hilft! Aktion: www.deutschlandsegelt.de Unser Dankeschön: Ihr Name auf dem Segel der 1. deutschen America's Cup-Yacht! |
From: Alessandro P. <al...@ti...> - 2006-12-05 09:03:15
|
Hello, sorry for the long post. I'm using pmapper 3. I have a layer which is a result of a M2M relationship, this means that a single feature is a result of multiple segments, and the id of the feature is unique while the id of single segments can be shared among several features. Everything works fine (more or less) but I found (a bug?) that highlight shows only the last segment of the result set. To make it work I had to change the initmap.php so that instead of the last segment, *all* the single segments are added to the session highlight var (see "ABP:" comments in the code). Basically, the for loop checks all results but only the id of the last is stored in the session variable (which is an array anyway). Should I file a bug for this or is it intentional ? /** * FUNCTION TO RETURN URL FOR MAPFRAME * used for starting application with pre-defined extent * extent read from shape features */ function getMapInitURL($map, $zoomLayer, $zoomQuery) { $qLayer = $this->map->getLayerByName($zoomLayer); // Query parameters $queryList = split('@', $zoomQuery); $queryField = $queryList[0]; $queryFieldType = $queryList[1]; //$queryValue = "/^" . $queryList[2] ."$/"; $queryValue = $queryList[2]; $highlFeature = $queryList[3]; $setMaxExtent = $queryList[4]; // Modify filter for PostGIS & Oracle layers if ($qLayer->connectiontype == 6 || $qLayer->connectiontype == 8) { $q = $queryFieldType == 1 ? "'" : ""; #$queryValue = "$queryField = $q$queryValue$q"; //error_log($queryValue); $queryValue = $queryField . ' ~* \'' . $queryValue .'\' '; } else { // Shapefile } // Query layer ABP: fix mapscript 410 // (this is not related with highlight) $qLayer->queryByAttributes($queryField, "\"$queryValue\"", MS_MULTIPLE); $numResults = $qLayer->getNumResults(); $qLayer->open(); // Return query results (SINGLE FEATURE): shape index and feature extent /* $qRes = $qLayer->getResult(0); $qShape = $qLayer->getShape($qRes->tileindex,$qRes->shapeindex); $qShpIdx = $qShape->index; $qShpBounds = $qShape->bounds; */ // Check if layer has different projection than map // if yes, re-project extent from layer to map projection $mapProjStr = $this->map->getProjection(); $qLayerProjStr = $qLayer->getProjection(); if ($mapProjStr && $qLayerProjStr && $mapProjStr != $qLayerProjStr) { $mapProjObj = ms_newprojectionobj($mapProjStr); $qLayerProjObj = ms_newprojectionobj($qLayerProjStr); //$qShpBounds->project($this->qLayerProjObj, $this->mapProjObj); $reprojectShape = 1; } // initial max/min values $mExtMinx = 999999999; $mExtMiny = 999999999; $mExtMaxx = -999999999; $mExtMaxy = -999999999; // ABP: Store all shape indexes $qShpIdxArray = array(); // Return query results: shape index and feature extent for ($iRes=0; $iRes < $numResults; $iRes++) { $qRes = $qLayer->getResult($iRes); $qShape = $qLayer->getShape($qRes->tileindex,$qRes->shapeindex); $qShpIdx = $qShape->index; // ABP: Store all segments $qShpIdxArray[] = $qShpIdx; $qShpBounds = $qShape->bounds; if ($reprojectShape) { $qShpBounds->project($qLayerProjObj, $mapProjObj); } $shpMinx = $qShpBounds->minx; $shpMiny = $qShpBounds->miny; $shpMaxx = $qShpBounds->maxx; $shpMaxy = $qShpBounds->maxy; // Get max/min values of ALL features $mExtMinx = min($mExtMinx, $shpMinx); $mExtMiny = min($mExtMiny, $shpMiny); $mExtMaxx = max($mExtMaxx, $shpMaxx); $mExtMaxy = max($mExtMaxy, $shpMaxy); } //die(); // Apply buffer (in units of features) //$buffer = 20000; // <<<<<<<<<<<<<<<<<<<<<< ADAPT VALUE <<<<<<<<<<<<<<<<< // ABP: set buffer for points // (this is not related with highlight) if ($this->qLayerType == 0) { $buffer = $_SESSION["pointBuffer"]; } else { $buffer = 0.05 * ((($mExtMaxx - $mExtMinx) + ($mExtMaxy - $mExtMiny)) / 2); } // Set buffer for point layers $mExtMinx -= $buffer; $mExtMiny -= $buffer; $mExtMaxx += $buffer; $mExtMaxy += $buffer; $roundFact = ($map->units != 5 ? 0 : 6); $shpMinx = round($mExtMinx, $roundFact); $shpMiny = round($mExtMiny, $roundFact); $shpMaxx = round($mExtMaxx, $roundFact); $shpMaxy = round($mExtMaxy, $roundFact); $ext = array ($shpMinx, $shpMiny, $shpMaxx, $shpMaxy); $_SESSION['zoom_extparams'] = $ext; // Set Max Extent for map if ($setMaxExtent) { $mapMaxExt['minx'] = $shpMinx; $mapMaxExt['miny'] = $shpMiny; $mapMaxExt['maxx'] = $shpMaxx; $mapMaxExt['maxy'] = $shpMaxy; $_SESSION['mapMaxExt'] = $mapMaxExt; } // Add highlight feature if defined in URL parameters if ($highlFeature) { // ABP: add all shapes // $resultlayers[$zoomLayer] = array($qShpIdx); $resultlayers[$zoomLayer] = $qShpIdxArray; $_SESSION["resultlayers"] = $resultlayers; } // Return URL $searchString = "&mode=map&zoom_type=zoomextent&extent=" . $shpMinx ."+". $shpMiny ."+". $shpMaxx ."+". $shpMaxy . ($highlFeature ? "&resultlayer=$zoomLayer+$qShpIdx" : ""); $mapInitURL = "map.phtml?$searchString"; return $mapInitURL; } -- Alessandro Pasotti itOpen - "Open Solutions for the Net Age" w3: www.itopen.it Linux User# 167502 |
From: stirner m. <sti...@ho...> - 2006-12-05 03:50:23
|
Hi List, Hi Armin Armin, I have pmapper 3, i have an problems 1.. when written http://localhost/pmapper3/index.html I see index.html default, this is ok. rigth.. and later i click in (I just work with demodata in pmapper3) Small, layer flat view, English-------- The layout to appear, but map I don't watch -----I just watch gif of Downloading nothing more.. 2 when written http://localhost/pmapper3/index.html I see index.html default, this is ok, but clikc in 2ª option : Medium, layer tree view, German------- to appear the following error: Warning: dl() [function.dl]: Unable to load dynamic library '/ms4w/Apache/php/ext/php_mapscript_48.dll' - No se puede encontrar el m�dulo especificado. in C:\ms4w\Apache\htdocs\pmapper3\incphp\globals.php on line 49 Fatal error: Call to undefined function ms_newMapObj() in C:\ms4w\Apache\htdocs\pmapper3\incphp\globals.php on line 58 I say in config msversion= 48.... I don't understanding why to appear that error....... Armin you can healp me please...I sorry my Bad English Thanx all _________________________________________________________________ Visita MSN Latino Entretenimiento: ¡música, cine, chismes, TV y más...! http://latino.msn.com/entretenimiento/ |
From: Keith B. <kbo...@gm...> - 2006-12-04 18:39:28
|
Hi Armin, I had read through that thread on the list, and am in the same spot Stephan got to with defGroupList not defined, and as I looked at resolving my issue, it seemed I was essentially going through the steps of completely reloading the map. That's when I got discouraged and thought I'd check with the list..I was hoping someone on the list had gotten all the way through to a solution they were happy with. Of course it's my problem, and I have to solve it, I was just hoping someone might have a flash of insight :) My understanding of the legend code is rather muddled. thank for the pointer though, -Keith On 12/4/06, Armin Burger <arm...@gm...> wrote: > Keith > > try to use as a starting point this topic from the mailing list: > > http://www.mail-archive.com/pma...@li.../msg00494.html > > There is an attached PHP script for adding layers dynamically and the > explanations for it is in a mail later in that posting. They are > hopefully possible to understand. > > armin > > Keith Boyle wrote: > > Sorry for my delayed response, and as always thank you for the reply. > > I should have been more complete in describing what I'm up to, dynamic > > legends is too vague. Please forgive me if the following is too > > detailed: > > > > I'm implementing user created layers in postgres/postgis, allowing the > > user to create certain combinations of existing layers > > (intersections), distance envelopes (buffers) around selected classes > > of selected layers, and even uploading some basic data to create new > > points/shapes. > > > > I've set up two tables for describing layers, a 'layers' table and a > > 'classes' table that are read after the map file is read. Then through > > php/mapscript I'm adding the layers to the map created by the map > > file. > > > > All this I'm making progress on, but getting the legend to show the > > new layers I've added via mapscript is really eluding me. For now, I'm > > reloading the entire map.phtml page after the user creates a new > > layer. This works but seems very 'heavy handed' and not very elegant. > > If there is a better way, I'd love to go that path instead. > > > > Please let me know if you have any suggestions or pointers, I've dug > > through the code base but haven't found a solution to my issue that > > behaves well... > > > > again, as always, many thanks Armin for a great baseline from which to > > build! > > -Keith > > > > > > On 12/1/06, Armin Burger <arm...@gm...> wrote: > >> what do you mean exactly with 'dynamic legends'? > >> > >> In the current implementation you have the possibility to combine both > >> TOC and legend, typically in a foldable tree structure. Then the > >> legend icons are never updated. Or you swap between TOC and legedn > >> view, then the legend just shows the icons of the visible layers. > >> > >> *Real* dynamic legends with displaying only the icons of visible > >> classes on the current map extent are something I would like to have > >> but this would require a base function available via Mapscript. > >> > >> armin > > > |
From: Armin B. <arm...@gm...> - 2006-12-04 18:29:46
|
Keith try to use as a starting point this topic from the mailing list: http://www.mail-archive.com/pma...@li.../msg00494.html There is an attached PHP script for adding layers dynamically and the explanations for it is in a mail later in that posting. They are hopefully possible to understand. armin Keith Boyle wrote: > Sorry for my delayed response, and as always thank you for the reply. > I should have been more complete in describing what I'm up to, dynamic > legends is too vague. Please forgive me if the following is too > detailed: > > I'm implementing user created layers in postgres/postgis, allowing the > user to create certain combinations of existing layers > (intersections), distance envelopes (buffers) around selected classes > of selected layers, and even uploading some basic data to create new > points/shapes. > > I've set up two tables for describing layers, a 'layers' table and a > 'classes' table that are read after the map file is read. Then through > php/mapscript I'm adding the layers to the map created by the map > file. > > All this I'm making progress on, but getting the legend to show the > new layers I've added via mapscript is really eluding me. For now, I'm > reloading the entire map.phtml page after the user creates a new > layer. This works but seems very 'heavy handed' and not very elegant. > If there is a better way, I'd love to go that path instead. > > Please let me know if you have any suggestions or pointers, I've dug > through the code base but haven't found a solution to my issue that > behaves well... > > again, as always, many thanks Armin for a great baseline from which to > build! > -Keith > > > On 12/1/06, Armin Burger <arm...@gm...> wrote: >> what do you mean exactly with 'dynamic legends'? >> >> In the current implementation you have the possibility to combine both >> TOC and legend, typically in a foldable tree structure. Then the >> legend icons are never updated. Or you swap between TOC and legedn >> view, then the legend just shows the icons of the visible layers. >> >> *Real* dynamic legends with displaying only the icons of visible >> classes on the current map extent are something I would like to have >> but this would require a base function available via Mapscript. >> >> armin > |
From: Keith B. <kbo...@gm...> - 2006-12-04 17:26:32
|
Sorry for my delayed response, and as always thank you for the reply. I should have been more complete in describing what I'm up to, dynamic legends is too vague. Please forgive me if the following is too detailed: I'm implementing user created layers in postgres/postgis, allowing the user to create certain combinations of existing layers (intersections), distance envelopes (buffers) around selected classes of selected layers, and even uploading some basic data to create new points/shapes. I've set up two tables for describing layers, a 'layers' table and a 'classes' table that are read after the map file is read. Then through php/mapscript I'm adding the layers to the map created by the map file. All this I'm making progress on, but getting the legend to show the new layers I've added via mapscript is really eluding me. For now, I'm reloading the entire map.phtml page after the user creates a new layer. This works but seems very 'heavy handed' and not very elegant. If there is a better way, I'd love to go that path instead. Please let me know if you have any suggestions or pointers, I've dug through the code base but haven't found a solution to my issue that behaves well... again, as always, many thanks Armin for a great baseline from which to build! -Keith On 12/1/06, Armin Burger <arm...@gm...> wrote: > what do you mean exactly with 'dynamic legends'? > > In the current implementation you have the possibility to combine both TOC and legend, typically in a foldable tree structure. Then the legend icons are never updated. Or you swap between TOC and legedn view, then the legend just shows the icons of the visible layers. > > *Real* dynamic legends with displaying only the icons of visible classes on the current map extent are something I would like to have but this would require a base function available via Mapscript. > > armin |
From: Chris B. <be...@xs...> - 2006-12-04 16:24:40
|
I have created a html document to get input from the user. On this form I created a button which runs some PHP code. After running the code I want to close the form automatically. How do I do this? Thanks, Chris Beaart. |
From: Armin B. <arm...@gm...> - 2006-12-03 18:03:24
|
just google for it and you will get lots of hits. Newer versions of Mysql need different client authentication. I would try to use $db_type = "mysqli" instead of the older "MYSQL" interface and see if it solves the problem. from PEAR DB docs (http://pear.php.net/manual/en/package.database.db.intro-dsn.php) mysqli -> MySQL (for MySQL >= 4.1) (requires PHP 5) (since DB 1.6.3) Or use any of the suggested solutions from google, like this one http://dev.mysql.com/doc/refman/5.0/en/old-client.html armin Chris Beaart wrote: > Wow, that's a quick answer. > I tried your hints. Running the exact created SQL-string in the DB-console > works perfectly. > When I enter the more verbose logging code I get the following message: > [nativecode=Client does not support authentication protocol requested by > server; consider upgrading MySQL client] ** > mysql://root:password@localhost/dop > > Do you have any further suggestions? > Thanks, > Chris. > > > -----Oorspronkelijk bericht----- > Van: pma...@li... > [mailto:pma...@li...] Namens Armin Burger > Verzonden: zondag 3 december 2006 16:37 > Aan: Chris Beaart > CC: pma...@li... > Onderwerp: Re: [pmapper-users] Nothing happens while trying to connect to > MYSQL database > > use some more verbose logging after connection and query, like > > if (DB::isError($dbh)) { > error_log($dbh->getDebugInfo()); > } > > > if (DB::isError($result)) { > error_log($result->getDebugInfo()); > } > > > And try what happens when you want to run the created SQL string from a > DB console. > > Armin > |
From: Armin B. <arm...@gm...> - 2006-12-03 15:36:35
|
use some more verbose logging after connection and query, like if (DB::isError($dbh)) { error_log($dbh->getDebugInfo()); } if (DB::isError($result)) { error_log($result->getDebugInfo()); } And try what happens when you want to run the created SQL string from a DB console. Armin Chris Beaart wrote: > I'm using the script below. However while trying to connect to the MYSQL > database nothing happens (also no PHP error). What could be wrong? > > > > Thank, > > Chris Beaart. > > > > ------------------ > > > > <?php > > require_once ("C:/ms4w/Apache/php/PEAR/DB.php"); > > session_start(); > > require_once("common.php"); > > > > function DB_addPoint($imgxy, $soort, $waarneming, $datum) > > { > > $db_host = "localhost"; > > $db_type = "MYSQL"; > > $db_name = "database"; > > $db_user = "root"; > > $db_pwd = "password"; > > > > $dsn = "$db_type://$db_user:$db_pwd@$db_host/$db_name"; > > error_log ($dsn); > > #MYSQL://root:password@localhost/database > > > > // CONVERT PIXEL X/Y TO MAP UNITS > > $imgxy_arr = explode(" ", $imgxy); > > $x_pix = $imgxy_arr[0]; > > $y_pix = $imgxy_arr[1]; > > $GEOEXT = $_SESSION["GEOEXT"]; > > $geoDeltaX = $GEOEXT["maxx"] - $GEOEXT["minx"]; > > $geoDeltaY = $GEOEXT["maxy"] - $GEOEXT["miny"]; > > $mapW = $_SESSION["mapwidth"]; > > $mapH = $_SESSION["mapheight"]; > > $x_geo = round($GEOEXT["minx"] + (($x_pix/$mapW)*$geoDeltaX)); > > $y_geo = round($GEOEXT["maxy"] - (($y_pix/$mapH)*$geoDeltaY)); > > > > // CONNECT TO DB AND RUN QUERY > > //$geometry = "GeomFromText('POINT($x_geo $y_geo)',26591)"; > > $sql = "INSERT INTO waarnemingen(x,y,soort,waarneming) > VALUES($x_geo,$y_geo,'$soort','$waarneming')"; > > #error_log ($sql); > > > > # SOMEWHERE HERE GOES SOMETHING WRONG > > $dbh = dbConnect($dsn); > > $result = $dbh->query($sql); > > > > // Check that $result is not an error > > if (DB::isError($result)) { > > $dbh->disconnect(); > > return ($result->getMessage()); > > } else { > > $dbh->disconnect(); > > return 1; > > } > > } > > > > function dbConnect($dsn) > > { > > $dbh = DB::connect($dsn); > > if (DB::isError($dbh)) { > > die ($dbh->getMessage()); > > return NULL; > > } else { > > return $dbh; > > } > > } > > > > ?> > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys - and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > pmapper-users mailing list > pma...@li... > https://lists.sourceforge.net/lists/listinfo/pmapper-users > |
From: Chris B. <be...@xs...> - 2006-12-03 15:23:24
|
I'm using the script below. However while trying to connect to the MYSQL database nothing happens (also no PHP error). What could be wrong? Thank, Chris Beaart. ------------------ <?php require_once ("C:/ms4w/Apache/php/PEAR/DB.php"); session_start(); require_once("common.php"); function DB_addPoint($imgxy, $soort, $waarneming, $datum) { $db_host = "localhost"; $db_type = "MYSQL"; $db_name = "database"; $db_user = "root"; $db_pwd = "password"; $dsn = "$db_type://$db_user:$db_pwd@$db_host/$db_name"; error_log ($dsn); #MYSQL://root:password@localhost/database // CONVERT PIXEL X/Y TO MAP UNITS $imgxy_arr = explode(" ", $imgxy); $x_pix = $imgxy_arr[0]; $y_pix = $imgxy_arr[1]; $GEOEXT = $_SESSION["GEOEXT"]; $geoDeltaX = $GEOEXT["maxx"] - $GEOEXT["minx"]; $geoDeltaY = $GEOEXT["maxy"] - $GEOEXT["miny"]; $mapW = $_SESSION["mapwidth"]; $mapH = $_SESSION["mapheight"]; $x_geo = round($GEOEXT["minx"] + (($x_pix/$mapW)*$geoDeltaX)); $y_geo = round($GEOEXT["maxy"] - (($y_pix/$mapH)*$geoDeltaY)); // CONNECT TO DB AND RUN QUERY //$geometry = "GeomFromText('POINT($x_geo $y_geo)',26591)"; $sql = "INSERT INTO waarnemingen(x,y,soort,waarneming) VALUES($x_geo,$y_geo,'$soort','$waarneming')"; #error_log ($sql); # SOMEWHERE HERE GOES SOMETHING WRONG $dbh = dbConnect($dsn); $result = $dbh->query($sql); // Check that $result is not an error if (DB::isError($result)) { $dbh->disconnect(); return ($result->getMessage()); } else { $dbh->disconnect(); return 1; } } function dbConnect($dsn) { $dbh = DB::connect($dsn); if (DB::isError($dbh)) { die ($dbh->getMessage()); return NULL; } else { return $dbh; } } ?> |
From: Steffen M. <sdt...@gm...> - 2006-12-03 06:24:55
|
Eric, I got ArSDE working with MS4W 1.5.5. (2.* was not out when we did this. I a= ssume the same thing will work with 2.*) The connection string was tricky and the ArcSDE messages were not really helpful. Have a look at the connection string below. Regards, Steffen layer CONNECTION "servername,esri_sde,sde,username,password" CONNECTIONTYPE SDE DATA "awc.awc_quera,shape" FILTER "WHERE SHAPE IS NOT NULL" type line status default class template "ttt_query.html" name "Basemap" color 170 170 170 end maxscale 20000 tolerance 1 METADATA "DESCRIPTION" "Basemap" "RESULT_FIELDS" "AREA" END end On 12/2/06, Armin Burger <arm...@gm...> wrote: > Eric > if you have SDE on the same machine as Mapserver just add the dir with > sde91.dll to the system path. If not, you can run mapserv.exe and it > will tell you which dll is missing. Search that dll and copy it under a > dir in the system path (I usually create one for mapserver purposes). > Iteratively you should achieve to get all required dll's. Then try to > create a map with simple tools like shp2img. > > Note that this question is no way related to p.mapper and on the > Mapserver mailing list you will for sure find better support for it. > > armin > > Eric Allard wrote: > > Thanks Armin! > > > > I installed my application on MS4W 2.2.1 running Pmapper 1.9.5. It seem= s > to > > be working fine on PhpMapscript 4.10 and POSTGIS 8.0! > > > > Now I get this error when working with SDE 9.1 layer! > > I know it's not your software... :) > > > > ERROR: > > Warning: [MapServer Error]: msSDELayerOpen(): SE_connection_create(): > > Operation Failed. (-1) in > > > C:\p4_eric\projects\relocengine\projects\Akyem\main\carto\pmapper2\incphp= \in > > itgroups.php on line 229 > > > > I checked my connection string... and it seems OK! I suspect the DATA > > string! > > > > I double check my SDE layer with ArcExplorer, and I can see it! > > SDE.DBO.ERIC > > > > Here's my Mapfile layer. > > > > ... > > LAYER > > NAME "MineInfra" > > TYPE POLYGON > > STATUS ON > > CONNECTION "localhost,port:5151,sde,sa," > > CONNECTIONTYPE SDE > > DATA "SDE.DBO.ERIC,shape," > > FILTER "where shape is not NULL" > > CLASS > > TEMPLATE void > > NAME "Phase 1" > > COLOR 150 185 255 > > OUTLINECOLOR 110 110 110 > > END > > END # LAYER > > > > > > QUESTIONS: > > The link you gave me, > > http://maptools.org/ms4w/index.phtml?page=3DREADME_INSTALL.html#sde-9-1 > > > > THEY SAY: > > 1- Make sure the ArcSDE SDK dlls for 9.1 are available on your machin= e > > (the same machine that you are running MS4W on).. > > > > -Q: Should I copy all those Dlls to a specific MS4W dir? > > > > I appreciate your time on this! > > -Eric > > > > -----Message d'origine----- > > De : Armin Burger [mailto:arm...@gm...] > > Envoy=E9 : 30 novembre 2006 16:54 > > =C0 : Eric Allard > > Cc : pma...@li... > > Objet : Re: [pmapper-users] Mapscript connection to ArcSDE! > > > > You should try it with the latest ms4w version from maptools.org (you > > will need to change all your MS and PHP related libraries to be sure it > > works, so MS 4.10 and PHP 5.2). Seems like they have support for SDE > > =3D> http://maptools.org/ms4w/index.phtml?page=3DREADME_INSTALL.html#sd= e-9-1 > > > > armin > > > > Eric Allard wrote: > >> Hi! All! > >> > >> After trying the following SDE layer connection, I get the following > > error: > >> Warning: [MapServer Error]: msSDELayerOpen(): SDE support is not > > available. > >> in > >> > > > C:\p4_eric\projects\relocengine\projects\Akyem\main\carto\pmapper2\incphp= \in > >> itgroups.php on line 229 > >> > >> My setup: > >> -Windows XP > >> -MSSQL 2000 > >> -ArcSDE 9.1 (As a service) > >> -Apache 2.0.X > >> -PHP 5.0.5 > >> -Pmapper 1.9.5 > >> -php_mapscript_46.dll (Loaded at PHP start) > >> > >> My Mapfile connection: > >> CONNECTION "localhost,port:5151,sde,sa,''," > >> CONNECTIONTYPE SDE > >> DATA "SDE.DBO.ERIC,LAYER,SDE.DEFAULT" > >> > >> Question: > >> 1. How do I link the phpmapscrip.dll to use sde91.dll (Or other needed > > srv)? > >> > >> Link to the phpmapscrip46 used: > >> - Binary Packages - Win32 > >> - mapserver-4.6.1-win32-php5.0.5.zip ~16 MB > >> http://www.maptools.org/php_mapscript/index.phtml?page=3Ddownloads.htm= l > >> > >> Thanks! > >> -Eric > >> > > > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share y= our > opinions on IT & business topics through brief surveys - and earn cash > http://www.techsay.com/default.php?page=3Djoin.php&p=3Dsourceforge&CID=3D= DEVDEV > _______________________________________________ > pmapper-users mailing list > pma...@li... > https://lists.sourceforge.net/lists/listinfo/pmapper-users > |