javascript - Undefined error when embedding SVG -


i' using ajax call retrieve htm file builds svg. call returns file area it's suppose appear says:

enter image description here

is timing issue? have ajax call in separate js file called after page loads.

function buildmap(){     var lbmp = document.getelementbyid("lbmp-map");     if(lbmp != null){         $.ajax({              url:'../footer.htm',             method: 'get',             success: function(response){                 lbmp.innerhtml = response.responsetext;             },             failure: function(response){                 lbmp.innerhtml = "<p>failure</p>";             }         });      } } 

on success, ajax gives directly content, html in response , not in response.responsetext, that's why getting undefined message.


Comments

Popular posts from this blog

sublimetext3 - what keyboard shortcut is to comment/uncomment for this script tag in sublime -

java - No use of nillable="0" in SOAP Webservice -

ubuntu - Laravel 5.2 quickstart guide gives Not Found Error -