WordPress action hook
wp_session_commit
Fired by 22 WordPress plugins, running on 563K+ sites between them.
“Session has been written to the database”
How to use wp_session_commit
It's an action: your callback runs at that point. Nothing needs to be returned.
Add this to your theme's functions.php or a small custom plugin:
add_action( 'wp_session_commit', function() {
// Your code runs here.
}, 10, 1 );Argument names come from Ninja Forms's source. Other plugins may pass different values: check the call in the plugin you're targeting below.
22 plugins that fire wp_session_commit
Sorted by active installs. Each entry shows where the plugin calls the hook and what it passes.
-
Ninja Forms500,000+ installs
do_action( 'wp_session_commit' )includes/Libraries/Session/wp-session.php:117 -
WP Travel Engine20,000+ installs
do_action( 'wp_session_commit' )includes/lib/wp-session/wp-session.php:126 -
Charitable10,000+ installs
do_action( 'wp_session_commit' )includes/libraries/wp-session/wp-session.php:149 -
NP Quote Request for WooCommerce8,000+ installs
do_action( 'wp_session_commit' )wp-session-manager/includes/php-session.php:132 -
eCommerce Product Catalog7,000+ installs
do_action( 'wp_session_commit' )ext-comp/wp_session/wp-session.php:126 -
Easy Property Listings5,000+ installs
do_action( 'wp_session_commit' )lib/includes/libraries/wp-session.php:126 -
WP Delicious4,000+ installs
do_action( 'wp_session_commit' )src/lib/wp-session/wp-session.php:115 -
WP Travel3,000+ installs
do_action( 'wp_session_commit' )inc/lib/wp-session/wp-session.php:118 -
Restaurant Menu and Food Ordering2,000+ installs
do_action( 'wp_session_commit' )classes/libs/wp_session/wp-session.php:118 -
RestroPress1,000+ installs
do_action( 'wp_session_commit' )includes/libraries/wp-session.php:98 -
WP Session Manager1,000+ installs
do_action( 'wp_session_commit' )includes/deprecated.php:163 -
MAS Videos1,000+ installs
do_action( 'wp_session_commit' )includes/libraries/wp-session.php:117 -
Product Catalog Simple1,000+ installs
do_action( 'wp_session_commit' )core/ext-comp/wp_session/wp-session.php:126 -
WP BASE Booking of Appointments, Services and Events100+ installs
do_action( 'wp_session_commit' )includes/lib/wp-session.php:117 -
Simple Sponsorships80+ installs
do_action( 'wp_session_commit' )includes/libraries/wp-session.php:117 -
EduAdmin Booking60+ installs
do_action( 'wp_session_commit' )libraries/wp-session.php:113 -
wpGraphicStudio10+ installs
do_action( 'wp_session_commit' )includes/libraries/wp-session.php:114 -
Widget Master10+ installs
do_action( 'wp_session_commit' )includes/includes/wp-session.php:116 -
AllWebMenus WordPress Menu Plugin10+ installs
do_action( 'wp_session_commit' )wp-session-manager-master/wp-session.php:114 -
Post and Page Protect with Azure ADFewer than 10 installs
do_action( 'wp_session_commit' )vendors/wp-session-manager/includes/wp-session.php:134 -
MZ MBO AccessFewer than 10 installs
do_action( 'wp_session_commit' )libraries/wp-sessions/deprecated.php:163 -
SWidget for Carnegie Museums of PittsburghFewer than 10 installs
do_action( 'wp_session_commit' )edd/libraries/wp-session.php:117
Need a customisation built on this hook?
Tell us what you want to change and which plugin it's for. We'll write it, test it and send it back as a small plugin.