[ka-Map-users] Hilite query

Cheung Alan Kwok Lun ache051 at ec.auckland.ac.nz
Wed Mar 28 16:44:46 EST 2007

Hi  Camilo and Lorenzo,
The simplest method I could found to implement hilite in raster format:

1) Copy  <script type="text/javascript" 
src="tools/query/queryManager.js"></script> and <script 
type="text/javascript" src="tools/query/queryLayer.js"></script> to 

2) Copy and Paste 
line 105 from querymanager to myQuery event of startUp.js

3) Copy and Paste myQManager= new _queryManager(myKaMap,'searchres'); to 
function myOnLoad() in the startup.js

To change the look on the hilite item, look at tile_query.php

For example changing  $colorObj    = $styleObj->outlinecolor; on line 
420 to $colorObj    = $styleObj->color; would change highlighting using 
outline to highlight using a fill. Default hightlighting colour can be 
changed  at line 260 or it can be defined individually in the METADATA 
tag under LAYER object in the mapfile using the tag  "rgbColor" 
"XXX,XXX,XXX". There are heaps waiting to be explored! :)

I'm still investigating vector hiliting, I could generate the 
appropriate xml file using  queryTable.php but the loadXML function 
couldn't handle the dynamically generated XML codes? It would work if I 
manually save the XML into a file and get loadXML to load it though.....

I hope this helps! Tell me whether it works on your side :)

More information about the ka-Map-users mailing list