
nmsinc
User
Dec 30, 2011, 1:52 PM
Post #3 of 7
(1172 views)
Shortcut
|
Hi Tom, I have tried to impliment your suggestion with no luck - I'm using the code for multiple addresses that's suggested with the CMS plugin below, can you provide edits to accomplish what I need using this code? Thanks - nmsinc <!-- Start Map Here --> <!-- STEP2: Map with multiple addresses: add this to body tag: onload="initialize() --> <body onload="initialize()"> <!-- STEP2: Map with multiple addresses --> <h1><font size="5">Attraction & Fun things to do in Alliance</font></h1> <p>TIP: Click on markers for more details.</p> <!-- STEP3: Map with multiple addresses: Put this where you want your map disattractionsed, rename $myRecords if needed --> <?php $hasAddresses = array_filter(array_pluck($attractionsRecords, 'latitude')); ?> <?php if ($hasAddresses): ?> <div id="map_canvas" style="width: 550px; height: 950px; float: left; margin: 0px 15px;"></div> <?php endif ?> <?php if (!$hasAddresses): ?> <div style="width: 650px; height: 550px; float: left; margin: 0px 15px; border: 1px solid #000;"> <div style="text-align: center; padding-top: 135px"> No map available! </div> </div> <?php endif ?> <!-- STEP3: /Map with multiple addresses --> <!-- STEP4: Map with multiple addresses: Set the popup window content, rename $myrecords if needed --> <div id="marker_details" style="display: none;"> <?php foreach ($attractionsRecords as $record): ?> <?php // marker_infowindow_### is the content disattractionsed in the info-window on click ?> <div id="marker_infowindow_<?php echo $record['num']; ?>" style="position: absolute; top: 1132px; left: 722px; width: 26px; height: 28px; z-index: 1"> <font size="2"> <b><?php echo $record['title'] ?></b></br> <font size="1"> <?php echo $record['address'] ?><br/> <?php echo $record['city'] ?>, <?php echo $record['state'] ?>, <?php echo $record['zip'] ?><br> <!-- Upload Fields: num, createdTime, tableName, fieldName, recordNum, preSaveTempId, filePath, filename, extension, thumbFilePath, isImage, hasThumbnail, urlPath, width, height, thumbUrlPath, thumbWidth, thumbHeight, info1, info2, info3, info4, info5 --> <?php foreach ($record['images'] as $upload): ?> <?php if ($upload['hasThumbnail']): ?> <img src="<?php echo $upload['thumbUrlPath'] ?>" width="<?php echo $upload['thumbWidth'] ?>" height="<?php echo $upload['thumbHeight'] ?>" alt="" /><br/> <?php endif ?> <?php endforeach ?> <!-- <a href="<?php echo $record['_link']; ?>">details</a> --> </div> <?php endforeach ?> </div> <!-- STEP4: Map with multiple addresses --> <!-- End Map Here -->
|