Answer the question
In order to leave comments, you need to log in
Why do HTML tags appear in the API response?
I made an API on the site that returns a JSON response! But when I decode it with json_decode() it returns null! All this because of HTML tags!
The question is why are they there? I do not prescribe them in the API response!
Answer example:
<html><head></head><body>{"code":"200","message":"OK","data":"0"}</body></html>
Answer the question
In order to leave comments, you need to log in
If you encounter this problem, then it is most likely due to the fact that your php script does not work in CGI!
If it is not possible to enable CGI, you will have to additionally process the response and remove all html tags!
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question