These actions and filters are available for use in your theme or plugin.
wp_otis_before_fetch_listings
do_action( 'wp_otis_before_fetch_listings', $assoc_args );
This action is fired before each fetch of listings from the OTIS API. The listings are fetched in pages based on results from OTIS and the page is set by the page
argument. These fetches are stored in a transient for use in the process listings step.
$assoc_args
- The arguments passed to the WP-OTIS function.
wp_otis_after_fetch_listings
do_action( 'wp_otis_after_fetch_listings', $assoc_args );
This action is fired after the last fetch of listings from the OTIS API.
$assoc_args
- The arguments passed to the WP-OTIS function.
wp_otis_before_process_listings
do_action( 'wp_otis_before_process_listings', $assoc_args );
This action is fired before each page of listings is processed. The listings are processed in chunks of 100 and the page is determined by the modified_process_page
argument.
$assoc_args
- The arguments passed to the WP-OTIS function.
wp_otis_after_process_listings
do_action( 'wp_otis_after_process_listings', $assoc_args );
This action is fired after the last page of listings is processed.
$assoc_args
- The arguments passed to the WP-OTIS function.
wp_otis_before_delete_removed_listings
do_action( 'wp_otis_before_delete_removed_listings', $assoc_args );
This action is fired before each page of listings is deleted. The listings are deleted in chunks based on OTIS results and the page is determined by the deletes_page
argument.
$assoc_args
- The arguments passed to the WP-OTIS function.
wp_otis_after_delete_removed_listings
do_action( 'wp_otis_after_delete_removed_listings', $assoc_args );
This action is fired after the last page of listings is deleted.
$assoc_args
- The arguments passed to the WP-OTIS function.
wp_otis_before_sync_all_listings
do_action( 'wp_otis_before_sync_all_listings', $assoc_args );
This action is fired before each page of listings is fetched from OTIS. The listings page is determined by the sync_page
argument.
$assoc_args
- The arguments passed to the WP-OTIS function.
wp_otis_after_sync_all_listings
do_action( 'wp_otis_after_sync_all_listings', $assoc_args );
This action is fired after the last page of listings is fetched from OTIS.
$assoc_args
- The arguments passed to the WP-OTIS function.
wp_otis_before_process_active_listings
do_action( 'wp_otis_before_process_active_listings', $assoc_args );
This action is fired before each page of active listings is processed. The listings are processed in chunks of 100 and the page is determined by the process_page
argument.
$assoc_args
- The arguments passed to the WP-OTIS function.
wp_otis_after_process_active_listings
do_action( 'wp_otis_after_process_active_listings', $assoc_args );
This action is fired after the last page of active listings is processed.
$assoc_args
- The arguments passed to the WP-OTIS function.
wp_otis_before_import_active_listings
do_action( 'wp_otis_before_import_active_listings', $assoc_args );
This action is fired before each page of active listings is imported. The listings are imported in chunks of 100 and the page is determined by the import_page
argument.
$assoc_args
- The arguments passed to the WP-OTIS function.
wp_otis_after_import_active_listings
do_action( 'wp_otis_after_import_active_listings', $assoc_args );
This action is fired after the last page of active listings is imported.
$assoc_args
- The arguments passed to the WP-OTIS function.
wp_otis_cancel_import
do_action( 'wp_otis_cancel_import' );
This action is fired when the import is cancelled before cancel actions are taken.
wp_otis_listings
apply_filters( 'wp_otis_listings', $assoc_args );
This filter is used to modify the arguments passed to the WP-OTIS importer function. Expected to return an array of arguments.
$assoc_args
- The arguments passed to the WP-OTIS Importer function.
wp_otis_listings_api_params
apply_filters( 'wp_otis_listings_api_params', $assoc_args );
This filter is used to modify the arguments passed to the OTIS API in the fetch listings function used in modified POI syncing. Expected to return an array of arguments.
$assoc_args
- The arguments passed to the WP-OTIS Importer function.
wp_otis_before_process_listings_args
apply_filters( 'wp_otis_before_process_listings_args', $assoc_args );
This filter is used to modify the arguments passed to the WP-OTIS Importer function before processing listings. Expected to return an array of arguments.
$assoc_args
- The arguments passed to the WP-OTIS Importer function.
wp_otis_listings_to_process
apply_filters( 'wp_otis_listings_to_process', $listings_chunks[ $listings_page - 1 ], $listings_type );
This filter is used to modify the chunk of listings to be processed. Expected to return an array of listings to process.
$listings_chunk
- The chunk of listings to process.
$listings_type
- The type of listings being processed.
wp_otis_before_delete_removed_listings_args
apply_filters( 'wp_otis_before_delete_removed_listings_args', $assoc_args );
This filter is used to modify the arguments passed to the WP-OTIS Importer function before deleting removed listings. Expected to return an array of arguments.
$assoc_args
- The arguments passed to the WP-OTIS Importer function.
wp_otis_before_sync_all_listings_args
apply_filters( 'wp_otis_before_sync_all_listings_args', $assoc_args );
This filter is used to modify the arguments passed to the WP-OTIS Importer function before syncing all listings. Expected to return an array of arguments.
$assoc_args
- The arguments passed to the WP-OTIS Importer function.
wp_otis_processing_chunk_size
apply_filters( 'wp_otis_processing_chunk_size', $number_of_posts );
$number_of_posts
- The number of POIs to be processed at a time, defaults to 10 POIs.