Feed refresh¶
Use this cronjob to manually refresh the feeds which are managed in sections “Feeds” and are set to recurrence “Manually” (see Feeds).
The script to use can be found in ASA2’s subdirectory scripts
.
Execute it like this:
cd .../wordpress/wp-content/plugins/amazon-simple-affiliate/scripts
bash script.sh Asa2_Module_Feeds_Cron_Feeds
Setup¶
This configuration will execute the feeds resfresh task every hour (at minute zero, every hour).
0 * * * * /[wp_path]/wp-content/plugins/amazon-simple-affiliate/scripts script.sh Asa2_Module_Feeds_Cron_Feeds
To learn more about cronjobs, see Introduction.
Options¶
Note
Without options, this cronjob will refresh all active feeds.
id¶
The option id
is optional. It can be used to define the feeds to refreshed.
Possible values
ID (integer): The ID of one feed you want to refresh
List: A comma separated list of IDs to refresh multiple feeds at once, like: 1,2,3
You can find the ID in the first column of the feeds list table in section “Feeds”.

// ID example:
bash script.sh Asa2_Module_Feeds_Cron_Feeds -id=2
// List example:
bash script.sh Asa2_Module_Feeds_Cron_Feeds -id=1,2,3,5

lifetime¶
Use the lifetime
option to only include feeds with a last refresh time older than the defined lifetime in seconds.
For example, if you want to use the cronjob to only update feeds older than two hours, use a lifetime of 7200.
bash script.sh Asa2_Module_Feeds_Cron_Feeds --lifetime=7200
limit¶
Limits the number of feeds to be handled. If no limit is set, all feeds will be handled. The limit option makes perfect sense to be used together with option lifetime
.
bash script.sh Asa2_Module_Feeds_Cron_Feeds --limit=10
verbose¶
Use the verbose
option to get more information about the new items of a refrehed feed.
bash script.sh Asa2_Module_Feeds_Cron_Feeds --verbose
