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

routing - AngularJS State management ->load multiple states in one page -

python - GRASS parser() error -

post - imageshack API cURL -