This is a read-only archive of the Framer Community on Facebook.

What is Framer? Join the Community
Return to index
Jian Li
Posted Apr 22 - Read on Facebook

how to transcode this html code in framer?
<script type="text/javascript" src=""></script>
<script type="text/javascript">
var map = new AMap.Map('container',{
resizeEnable: true,
zoom: 10,
center: [116.480983, 40.0958]

I try to do this in framer:
map = new Layer
html: "<iframe src='>'</iframe>"

map.html += "<div id='map'></div>"
mapElement = p2_map.querySelector("#map") = pageDa.height+"px"

map = new (mapElement)

and I got a error:
ReferenceError: Can't find variable: AMap


Jordan Robert Dobson

Drop that script tag into the HTML

I think the issue is the code isn't ready yet and hasn't been evaluated.

If your REALLY want to use what you have... try putting a 10 second delay wrapped around your new map

Jian Li

thank your Jordan, it worked

Read the entire post on Facebook