Created
November 25, 2021 04:52
-
-
Save wtmujeebu/0ef6e1c128c0a235d88702e54c7a224d to your computer and use it in GitHub Desktop.
Import only the most recent file from FTP using Import export suite for WooCommerce by WebToffee
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php // Do not copy this line. | |
add_filter('wt_iew_folder_import_fetched_files','wt_import_latest_file',10,3); | |
if(!function_exists('wt_import_latest_file')){ | |
function wt_import_latest_file($server_csv_files,$ftp_conn,$remote_file){ | |
rsort($server_csv_files); | |
return array($server_csv_files[0]); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment