Forum Discussion
_anomDiebolt_
8 years agoQrew Elite
Everything is working properly - there is just some confusion over how to use the API calls.
The vast majority of the API methods return a single XML document as a response. The method API_GenAddRecordForm is an exception as it returns a HTML document as a response and included in this response are links and references to other resources such as JavaScript files, CSS files, font files etc.
When API_GenAddRecordForm is loaded from a hyperlink or entered into the address bar of a Browser, the Browser will make additional calls to the other resources and assembles everything into a visible page. However, when Postman loads API_GenAddRecordForm it only grabs the raw HTML response and does not request the other resources nor does Postman render the page (it isn't a browser and doesn't even have a rendering engine).
This explains everything your report.
The area where you are probably going astray is that in your JavaScfipt you are probably calling API_GenAddRecordForm using:
The vast majority of the API methods return a single XML document as a response. The method API_GenAddRecordForm is an exception as it returns a HTML document as a response and included in this response are links and references to other resources such as JavaScript files, CSS files, font files etc.
When API_GenAddRecordForm is loaded from a hyperlink or entered into the address bar of a Browser, the Browser will make additional calls to the other resources and assembles everything into a visible page. However, when Postman loads API_GenAddRecordForm it only grabs the raw HTML response and does not request the other resources nor does Postman render the page (it isn't a browser and doesn't even have a rendering engine).
This explains everything your report.
The area where you are probably going astray is that in your JavaScfipt you are probably calling API_GenAddRecordForm using:
$.get("...?act=API_GenAddRecordForm...")when you should be using:
document.location.href = "...?act=API_GenAddRecordForm..."