learndash_safe_redirect( string $location = '', int $status = null, bool $exit = true, string $context = '' )

Utility function to centralize all LearnDash redirect calls.


Description Description


Parameters Parameters

$location

(Optional) The URL to redirect the user to.

Default value: ''

$status

(Optional) The HTTP Status to set. Default 302.

Default value: null

$exit

(Optional) True if the function should exit on successful redirect.

Default value: true

$context

(Optional) Unique string provided by the caller to help filter conditions.

Default value: ''


Top ↑

Return Return

(bool) The redirect status. Only if $exit is not true.


Top ↑

Source Source

File: includes/ld-misc-functions.php


			

Top ↑

Changelog Changelog

Changelog
Version Description
3.2.3 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

You must log in before being able to contribute a note or feedback.