![]() |
external request for a file gives 404 - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: CodeIgniter 4 (https://forum.codeigniter.com/forumdisplay.php?fid=28) +--- Forum: CodeIgniter 4 Support (https://forum.codeigniter.com/forumdisplay.php?fid=30) +--- Thread: external request for a file gives 404 (/showthread.php?tid=92945) |
external request for a file gives 404 - PaulC - 05-22-2025 Hi Team, In our ci3 app we supply an external service with a web_url so they can take a copy of one of our files and analyse it before giving us a decision about its suitability for our site. In ci4 I have used exactly the same idea but the 3rd party is saying they receive a 404 response so we are not getting good responses. If I try to view the file in question by using the url I too get 404 but with a clue that the GET route is not defined. eg https://www.mysite.com/images/uploads/temp_dir/image.jpg I have reviewed the routing docs and the smart file handling docs but am a bit mystified about how to enable this file to be retrieved externally. I'm sure its easy but I cannot find the magic bullet ... yet. Any clues appreciated, thx Paul RE: external request for a file gives 404 - InsiteFX - 05-22-2025 PHP Code: Run - php spark Routes RE: external request for a file gives 404 - PaulC - 05-22-2025 OK I have run the spark command. Nice table of all my defined routes. How do I specify a route so that someone can read/copy a specific file? (or more generally and file written to a temporary directory with a random file in it) RE: external request for a file gives 404 - paulbalandan - 05-22-2025 Is that image found within public/images/uploads/temp_dir/? RE: external request for a file gives 404 - PaulC - 05-22-2025 No I have a link in public to ../../images |