![]() |
I want to test my API call using CI4. In development mode, I encountered errors in the browser console. How can I fix this?
.env PHP Code: #-------------------------------------------------------------------- Controller: TesApi.php PHP Code: public function tesApi() View: tesapi.php PHP Code: <body> Error in browser console: Code: Uncaught (in promise) SyntaxError: Unexpected token '<', "<script cl"... is not valid JSON Code: <script class="kint-rich-script">void 0===window.kintShared&&(window.kintShared=function(){"use strict";var e={dedupe:function(e,n){return[].forEach.call(document.querySelectorAll(e),function(e){e!==(n=n&&n.ownerDocument.contains(n)?n:e)&&e.parentNode.removeChild(e)}),n},runOnce:function(e){"complete"===document.readyState?e():window.addEventListener("load",e)}};return window.addEventListener("click",function(e){var n;e.target.classList.contains("kint-ide-link")&&((n=new XMLHttpRequest).open("GET",e.target.href),n.send(null),e.preventDefault())}),e}()); |
Messages In This Thread |
JavaScript Fetch returns an error when in development mode. - by Renta Ardhana - 07-12-2024, 08:21 AM
RE: JavaScript Fetch returns an error when in development mode. - by ozornick - 07-12-2024, 10:53 AM
RE: JavaScript Fetch returns an error when in development mode. - by kenjis - 07-15-2024, 03:33 PM
RE: JavaScript Fetch returns an error when in development mode. - by Renta Ardhana - 07-12-2024, 08:06 PM
RE: JavaScript Fetch returns an error when in development mode. - by kenjis - 07-15-2024, 03:36 PM
RE: JavaScript Fetch returns an error when in development mode. - by Renta Ardhana - 07-16-2024, 08:17 PM
|