php response is php content

php response is php content

oolcayoolcay Posts: 1Questions: 1Answers: 0

i use to datatable but ajax php response is php content file

when i run the php file output is true. but run my web application i get error that invalid json response

my datatable code is below.

Answers

  • colincolin Posts: 15,144Questions: 1Answers: 2,586

    That's a problem with your website, you haven't installed the PHP components correctly - I've done the same in the past. This SO thread should get you going - it's listing the steps you need to do.

    Colin

  • kthorngrenkthorngren Posts: 20,302Questions: 26Answers: 4,769
    edited October 2022

    Possibly you just need to add header('Content-type: application/json'); as discussed in this SO thread.

    Kevin

  • allanallan Posts: 61,723Questions: 1Answers: 10,108 Site admin

    I'd guess that PHP either isn't installed or that the HTTP server isn't setup to use PHP for .php files.

    What web-server are you using @oolcay?

    Allan

Sign In or Register to comment.