Skip to main content
Known Participant
February 16, 2010
Question

Google map inside the spry collapsible panel

  • February 16, 2010
  • 1 reply
  • 1470 views

So this time I've bumped into interesting 'bug'. I've placed the google map inside the spry collapsible panel. Panel is set to the closed mode on load of page. When I open the tab, map appears, but address marker is hidden behind the top left corner. If I place the same map outside the collapsiple panel it renders all well.

So my  question is whether there is any way around this issue. When I know where the marker is hidden I can simply move the map and see it, but customer who's not aware of the problem will see only blank map with not marked address which is not acceptable.

cheers,

Simon

    This topic has been closed for replies.

    1 reply

    Inspiring
    February 16, 2010

    Can you knock together a simple, stand-alone, self-contained bit of code that demonstrates this?

    --

    Adam

    Simon.DauAuthor
    Known Participant
    February 18, 2010

    Sure mate. Here you go:

    <div id="CollapsiblePanel1" class="CollapsiblePanel">
                  <div class="CollapsiblePanelTab" tabindex="0">SHOW MAP</div>
                  <div class="CollapsiblePanelContent">
                  <cfmap  width="242" height="200" zoomlevel="12" name="mainMap" markercolor="333444" showscale="false"
    typecontrol="none"  showcentermarker="true" centeraddress="#get_event.event_address1#, #get_event.event_address2#, #get_event.event_city#,#get_event.event_county#, #get_event.event_postcode#, #get_event.event_country#  "
    ></cfmap>
                  </div>
                </div>

    And this bit goes at the bottom of the code :

    <script type="text/javascript">

    var CollapsiblePanel1 = new Spry.Widget.CollapsiblePanel("CollapsiblePanel1", {contentIsOpen:false});
      </script>

    And that would be the preview that I get once the panel is open:

    And that is the preview of how it should look:

    As you can see the map marker sticks to the top left corner. I was wondering whether there is any way to re-focus it once the panel is open.

    cheers,
    Simon

    Inspiring
    February 18, 2010

    Um for future reference "stand-alone" and "self-contained" kind of imply that the code will just run without any adjustment if just copy and pasted into a file.  Your code snippet requires some additional data to exist: as it stands it just errors.

    --

    Adam