简体   繁体   中英

JSONP cross-domain call for html giving javascript errors

I'm making a JSONP cross-domain call through a developed API that enters html into a div. That attempt is causing key-word javascript errors (missing ; before statement, class is a reserved identifier, etc) and I really don't know where to start with this. The page can be accessed here: http://www.gounitedrealty.com/example.html and the code can be viewed through an "Inspect Element". I really don't know where/how to start with resolving this, and am hoping someone who has had a similar project can lend a hand or provide a suggestion.

Thanks very much

www.emenu.com/api/index.php?r=api/menu&host=www.gounitedrealty.com&callback=jQuery16406947022259701043_1317694125388&_=1317694126263:1 

is missing the most important part of JSONP, the JSON. It's HTML.

That's because it's invalid json. It's HTML.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM