enveetee Posted February 25, 2015 Share Posted February 25, 2015 I have a client application which runs a script on my server using HTTP POST How can I get a clean result of that script Currently, the script returns all sorts of headers, fonts and so on All I need is the name of the currently executing script (__file__?) and a result 1 or 0 plus any error message Suggestions please.. Quote Link to comment https://forums.phpfreaks.com/topic/294885-getting-the-result-of-a-php-script/ Share on other sites More sharing options...
rwhite35 Posted February 25, 2015 Share Posted February 25, 2015 Can you post any source? Also do you have error_reporting(E_ALL) somewhere at the top of the script. Perhaps you're getting notices and warning. But without some more details, its anybodies guess. Quote Link to comment https://forums.phpfreaks.com/topic/294885-getting-the-result-of-a-php-script/#findComment-1506706 Share on other sites More sharing options...
QuickOldCar Posted February 25, 2015 Share Posted February 25, 2015 Do your own logging on the script that saves a database or csv file, save whatever you want from it. You can use $_SERVER['REQUEST_URI'] which returns script,query,directory or $_SERVER['SCRIPT_NAME'] just the name of the script $_SERVER Quote Link to comment https://forums.phpfreaks.com/topic/294885-getting-the-result-of-a-php-script/#findComment-1506721 Share on other sites More sharing options...
Solution enveetee Posted February 25, 2015 Author Solution Share Posted February 25, 2015 Apologies everyone, brain fade here. I had echo statements inside include files which was wrecking the php output Sorry to waste everyone's time Quote Link to comment https://forums.phpfreaks.com/topic/294885-getting-the-result-of-a-php-script/#findComment-1506725 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.