Thanks Armin,

I will try to implement it somehow, but if we just ignore the map resizing
for a moment can you help about the things I mentioned in the last mail? I
can describe in details exactly what I did if this could help. I can give
you the access to this page so you can see what is happening :-))

thanks

dejan

> -----Original Message-----
> From: Armin Burger [mailto:armin.burger at gmx.net] 
> Sent: Thursday, May 25, 2006 6:55 PM
> To: Gambin Dejan
> Cc: pmapper-users at faunalia.it
> Subject: Re: [Pmapper-users] Dynamic map creation in pmapper
> 
> 
> the s1 value has to be updated dynamically all the time the map is 
> resized. This has to be achieved by a Javascript function 
> that gets the 
> new value based on the input parameters from the map (map height for 
> maximum zoom out in map coordinates) and height of the current map in 
> pixels.
> 
> An easy solution should be to write the initial max Y-extent 
> ($y_dgeo) 
> to a JS variable via PHP and then use this one to calculate 
> the new s1 
> value based on the updated map pixel-height. The Javascript function 
> would be similar to the 'returnmaxScale' in PHP. In most 
> cases you will 
> just set the map resolution to 96 (the most reasonable value for it 
> since most users are using Windows that assumes a screen 
> resolution of 
> 96). And if assumes that you have metric coordinates.
> 
> armin
> 
> Gambin Dejan wrote:
> > Hi Armin,
> > 
> > I have changed the returnMaxScale function in order to use my 
> > $_SESSION["initext"] value instead of map->extent values. This is 
> > updating the s1 value in frameview.phtml. Now the initial 
> map display 
> > correctly moves the slider to the start. But what do I have 
> to change 
> > to display it correctly after the zooming, etc? I see the slider 
> > position is modified in setSliderPosition function called 
> by setSlider 
> > called from map.phtml, but...
> > 
> > dejan
> > 
> >> -----Original Message-----
> >> From: Armin Burger [mailto:armin.burger at gmx.net]
> >> Sent: Tuesday, May 23, 2006 6:48 PM
> >> To: Gambin Dejan
> >> Cc: pmapper-users at faunalia.it
> >> Subject: Re: [Pmapper-users] Dynamic map creation in pmapper
> >>
> >>
> >> you will have to do something similar for 'pmap_setGeoExt()'
> >> in map.php around line ~203 ... $this->geoext0 = 
> >> $this->map->extent; ...
> >>
> >> if you use the slider you will also notice that the max
> >> values are not 
> >> correct. This needed some dynamic updating of the JS 's1' 
> >> value. On this 
> >> at least I will have once a look because it is also required for 
> >> consistent use of the slider in case where the map windows is 
> >> resizeable 
> >> with the mouse (pm 2 and latest dev for pm 1).
> >>
> >> armin
> >>
> >> Gambin Dejan wrote:
> >>> Thanks Armin,
> >>>
> >>> I have done it and it works ok except with "Back" button which can
> >>> still go to "Full extent"...."Home" button works OK, "Zoom 
> >> out" too...
> >>> dejan
> >>>
> >>>> -----Original Message-----
> >>>> From: Armin Burger [mailto:armin.burger at gmx.net]
> >>>> Sent: Monday, May 22, 2006 3:51 PM
> >>>> To: Gambin Dejan
> >>>> Cc: pmapper-users at faunalia.it
> >>>> Subject: RE: [Pmapper-users] Dynamic map creation in pmapper
> >>>>
> >>>>
> >>>> Dejan,
> >>>>
> >>>> I see a possibility by writing the initial (= max ) 
> extent as assoc 
> >>>> array to a session variable at the start. And then you have to 
> >>>> re-read this extent and use this one instad of the default.
> >>>>
> >>>> So, in map.php substitute line ~400 
> >>>>   $this->maxextent = $this->map->extent;
> >>>>
> >>>> with something like
> >>>>
> >>>> $initext = $_SESSION['initext']);
> >>>> $maxext = ms_newrectObj();     
> >>>> $maxext->setextent($initext["minx"],$initext["miny"],$initext[
> >>> "maxx"],$initext["maxy"]);
> >>>> $this->maxextent = $maxext;
> >>>>
> >>>>
> >>>> armin
> >>>>
> >>>>> --- Urspr?ngliche Nachricht ---
> >>>>> Von: "Gambin Dejan" <Dejan.Gambin at pula.hr>
> >>>>> An: "Armin Burger" <armin.burger at gmx.net>
> >>>>> Kopie: <pmapper-users at faunalia.it>
> >>>>> Betreff: RE: [Pmapper-users] Dynamic map creation in pmapper
> >>>>> Datum: Mon, 22 May 2006 13:09:50 +0200
> >>>>>
> >>>>> Hi Armin,
> >>>>>
> >>>>> I have done this like you described me. I have a tileindex
> >>>> shapefile
> >>>>> and I am zooming to the desired extent when clicking. The
> >>>> question is:
> >>>>> how can I configure the application so that user can 
> not zoom to 
> >>>>> larger extent than the one he used to open the map (for
> >> example the
> >>>>> map is opened with the desired extent but the user can
> >>>> click on Home
> >>>>> button or use "Zoom out" and
> >>>> get
> >>>>> the whole map and I don't want that). I have to dinamically
> >>>> limit the
> >>>>> scale?
> >>>>>
> >>>>> dejan
> >>>>>
> >>>>>> -----Original Message-----
> >>>>>> From: Armin Burger [mailto:armin.burger at gmx.net]
> >>>>>> Sent: Thursday, May 18, 2006 9:59 AM
> >>>>>> To: Gambin Dejan
> >>>>>> Cc: pmapper-users at faunalia.it
> >>>>>> Subject: Re: [Pmapper-users] Dynamic map creation in pmapper
> >>>>>>
> >>>>>>
> >>>>>> why don't you just put all your hotspot tiffs into an
> >> image catalog
> >>>>>> (strangely called 'tileindex' in mapserver). And then use this
> >>>>>> tileindex shapefile for zooming to the desired initial extent, 
> >>>>>> using the functionality to start the application 
> zoomed onto an 
> >>>>>> initial extent (there was a posting 2 days ago with 
> >> regard to this
> >>>>>> function).
> >>>>>>
> >>>>>> this functionality requires currently pmapper version 1,
> >> it's not
> >>>>>> included in version 2 yet. Since you do not mention
> >> which one you
> >>>>>> are using (as at least half of all others on this list),
> >> I cannot
> >>>>>> say if this is then working for you.
> >>>>>>
> >>>>>> armin
> >>>>>>
> >>>>>>> --- Urspr?ngliche Nachricht ---
> >>>>>>> Von: "Dejan Gambin" <dejan.gambin at pula.hr>
> >>>>>>> An: <pmapper-users at faunalia.it>
> >>>>>>> Betreff: [Pmapper-users] Dynamic map creation in pmapper
> >>>>>>> Datum: Wed, 17 May 2006 21:24:47 +0200
> >>>>>>>
> >>>>>>> Hi,
> >>>>>>>
> >>>>>>> I have an imagemap with 100 hotspot areas. Each hotspot is
> >>>>>> rectangular
> >>>>>>> area represented by one tiff file (about 170MB in size
> >> including
> >>>>>>> built-in overviews). When user clicks on a hotspot the map
> >>>>>> with this
> >>>>>>> area should be dsiplayed (maybe its neighbours too if this
> >>>>>> is not too
> >>>>>>> complicated).
> >>>>>>>
> >>>>>>> So, I have generated the imagemap and the Javascript 
> needed to 
> >>>>>>> open the pmapper window with proper arguments on user 
> click. But
> >>>>>> what about
> >>>>>>> the map files? I wouldn't like to have to generate a 
> hundred of 
> >>>>>>> map files. May I create the map file dynamically? Where to
> >>>> put the code?
> >>>>>>> thanks very much
> >>>>>>>
> >>>>>>> dejan
> >>>>>>>
> >>>>>>>
> >>>>>>> _______________________________________________
> >>>>>>> Pmapper-users mailing list
> >>>>>>> Pmapper-users at faunalia.it
> >>>>>>> http://faunalia.it/cgi-bin/mailman/listinfo/pmapper-users
> >>>>>>>
> >>>>>> --
> >>>>>> GMX Produkte empfehlen und ganz einfach Geld verdienen! Satte
> >>>>>> Provisionen f?r GMX Partner:
> >>>> http://www.gmx.net/de/go/partner
> >>>> --
> >>>> Mobile Internet - E-Mail und Internet immer und ?berall! GMX zum 
> >>>> Mitnehmen: http://www.gmx.net/de/go/pocketweb
> >>>>
> >>>
> > 
> > 
> 


Reply via email to