Header location not working properly

前端 未结 2 1649
自闭症患者
自闭症患者 2020-12-20 07:31

I have a php script that renders an image (with imagick) and saves it to some directory \"SITE_ROOT.$filePath\", then does a header(\'Location: \' . SITE_

2条回答
  •  失恋的感觉
    2020-12-20 08:04

    header('Location: ' . $filePath);

    SITE_ROOT is the location of the htdocs directory on the server; but header Location should be the path to the file relative to the htdocs directory

提交回复
热议问题