Hi

Medve Zsolt a écrit :
> Hy!
>
> I would like to ask some qouestion about p.mapper logics.
> 1. I see that the line in js_config.php :
>         {tool:'identify',      name:'Identify'}, is for the button to 
> apear in Tools. But where is the code of the image. Where and how it 
> will get the icon for the toolbar? I cant follow the logic. ( I need 
> this because if i want a custom functionality to pmapper, i want a 
> custom icon too, but if i write a button line to the js_config.php just 
> the text appears only.)
>
>   


The "tool" indicates image name.
In config/xxxxx/js_config.php you can specify the images theme and 
extension to use :
"PM.buttonsDefault = {
    toolbarid:'toolBar',
    options: {orientation:'v',
              css:{height:'auto'},
              theme:'theme2',
              imagetype:'gif'
             },
........"

Here "theme2" and "gif". The buttons images are calculated in 
pmapper/javascript/src/pm.uielements.js: image url = 'images/buttons/'+ 
options.theme + '/' + tool + '_off.' + options.imagetype.
For instance: pmapper/images/buttons/theme2/yourtool_off.gif

> 2. How p.mapper gets the id of a shape? I mean if i have a something.shp 
> file and have 1 or more shapes in it, how can i use for my own 
> functionality the ID of a shape?
> I need to pass this ID to a Soap Call.
>
>   
I don't really know what you want to do.

If you want to click on the map, find the shapes, call a SOAP service, 
you have to know PHP mapscript (http://mapserver.org/mapscript/index.html)

There are js functions ending with "_start(imgxy)". (see 
http://svn.pmapper.net/trac/wiki/FaqCustomizations#AddingaplugintotheGUI 
to know how to integrate your plugin). It will give you the xy 
coordinates (screen unit) of your click. You have to send them to your 
PHP file, convert the click in map unit, use PHP mapscript to project 
coordinates, search the shapes, and call tour SOAP service.

> Can someone help me a little bit more? I  would be gratefull.
>
> Thanks,
> Zsolt
>
>
>
>
>
> ------------------------------------------------------------------------------
> Download Intel® Parallel Studio Eval
> Try the new software tools for yourself. Speed compiling, find bugs
> proactively, and fine-tune applications for parallel performance.
> See why Intel Parallel Studio got high marks during beta.
> http://p.sf.net/sfu/intel-sw-dev
> _______________________________________________
> pmapper-users mailing list
> pmapper-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/pmapper-users
>
>
>
>
>
>   

------------------------------------------------------------------------------
Download Intel® Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
pmapper-users mailing list
pmapper-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/pmapper-users

Reply via email to