Note: You are viewing the documentation for Version 3View Version 4 Docs

Documentation

View the installation guide, browse the Knowledge Base, find out about SearchWP's many hooks, get support

Available since: 2.9.14

searchwp_dashboard_widget_transient_ttl

View Parameters »

By default SearchWP will use a transient to store Dashboard Widget data so as to improve performance. You can customize the duration of the time to live for this cached data:

<?php
add_filter( 'searchwp_dashboard_widget_transient_ttl', function( $duration ) {
// Only store Dashboard Widget data as transient for 1 hour (instead of default 12).
return HOUR_IN_SECONDS;
} );
view raw functions.php hosted with ❤ by GitHub

Parameters

Parameter Type Description
$ttl Integer

Number of seconds to cache widget data

Fix keyword search on your site. No coding required!

Now you can utilize all of the content that's gone unrecognized by native WordPress keyword search instantly with SearchWP

Get SearchWP