I am calling an API in a function that sends back a single line in text/plain
format, I was wondering how I can receive this information and put it into a string variable aString
.
When I use the API url in my chrome browser, I see the information that I need " MyInfo
".
Thanks,
turns out all I needed to do was append ***.text()
to the end of the response body.
If you are using jquery then you can use jquery promises to handle this scenario. A little more information from your end will help us to provide a better solution.
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.