0

I have completed upload file saved in temp path. How to read those file in cron every time file was new.

1 Answer 1

0

Without seeing the full code and having a detailed description, it’s difficult to provide a final solution, but I can suggest a helpful approach. You can use the filemtime() function, which retrieves the last modified time of a file. To handle the files in your cron job, you could save the timestamp of the file when it’s processed in your workflow. Later, you can compare the saved timestamp with the current modified time of the file. If the file is newer, you can process it; otherwise, you can skip it if it has already been processed.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.