• Hey,

    I would like to include WordPress API in an external file by including/requiring wp-load.php file.

    The problem is when the file is included, the script for some reason automatically redirects me to my WordPress home page and I can’t do nothing.

    I already tried any possible option to include the file but it still redirects me. Somebody already faced such a bug?

    Empty PHP file with this line is enough to redirect me:
    require_once(‘../wp-load.php’);

    Running on Linux.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Good Day!

    I have the same problem too. Using this line of code require_once(‘../wp-load.php’); is enough to use all of wordpress’ functions outside a wordpress site but doesn’t seem to work anymore on recent version of wordpress. As what have been mentioned by lance the script redirects to the wordpress home page.

    Can someone help us with our problem? Hoping for a response from wordpress’ support team.

    Thanks!

    Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    @glowkazaf, Please don’t use the modlook tag for this. WordPress isn’t a company, it’s the name of software that is freely distributed. People give support for the software, but that doesn’t mean “WordPress” has a support team.

    @andrew so where and who should we ask for help regarding this problem?

    Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    Right here on the forum just like @sance has done so. Better yet, create your own thread: https://www.ads-software.com/support/forum/how-to-and-troubleshooting#postform

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Can't include wp-load.php’ is closed to new replies.