If practical, you can use shell_exec or include php in the first file to run the second file. If it is placed at the end of the first file, it will be executed only if the script successfully reaches this point, and you can use php code to verify the successful completion of the first part.
source
share