[Cartoweb-users] trouble with new smarty template/ DHTML API

Oliver Christen oliver.christen at camptocamp.com
Tue Dec 4 04:06:03 EST 2007


Hi

you shouldnt touch the map element and its children as the dhtml is quite sensible to that, but you can enclose it in a parent element (div, table, ...) and then give a relative positionning to the parent, this should solve the miscalculation of the map element and its children.

regards
Oliver
  ----- Original Message ----- 
  From: karsten vennemann 
  To: cartoweb-users at lists.maptools.org 
  Sent: Tuesday, December 04, 2007 9:16 AM
  Subject: [Cartoweb-users] trouble with new smarty template/ DHTML API 


  Hi All,


  I'm working on a new smarty template for my cartoweb project. Map and leftbar show up, however the main map and its containing div don't line up:
   The map is unintentionally offset by 15px from the left and 69px down. In Firebug I can see that there is a tag
  <div id="map_rootLayer" class="layer" style="position: absolute; width: 700px; height: 500px; clip: rect(0px, 700px, 500px, 0px); left: 15px; top: 69px;"> that contains this unwanted off set but it seems that it somehow is attributed by cartoweb dynamically.

   

  I found this (uncomplete div) in the main.tpl of my project:


    <div id="map" class="map" style="width:{$mainmap_width}px;height:{$mainmap_height}px;">

  {* nothing here, DHTML API will run with the given class name *}

    </div>


  I couldn't figure out how to change the left and top offset (totally get rid of the offset), neither figure out where to find the DHTML API nor what it does.

  Any insights/explanation on what's going on here and how I can fix it?

  Thanks
  Karsten

   



------------------------------------------------------------------------------


  _______________________________________________
  Cartoweb-users mailing list
  Cartoweb-users at lists.maptools.org
  http://lists.maptools.org/mailman/listinfo/cartoweb-users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.maptools.org/pipermail/cartoweb-users/attachments/20071204/dad8b765/attachment.html


More information about the Cartoweb-users mailing list