llms_update_500_add_admin_notice()

Admin welcome notice


Return Return

(void)


Top ↑

Source Source

File: includes/functions/updates/llms-functions-updates-500.php

function llms_update_500_add_admin_notice() {

	require_once LLMS_PLUGIN_DIR . 'includes/admin/class.llms.admin.notices.php';

	$notice_id        = 'v500-welcome-msg';
	$get_started_link = add_query_arg(
		array(
			'post_type' => 'llms_form',
		),
		admin_url( 'edit.php' )
	);

	$html = sprintf(
		'<strong>%1$s</strong><br><br>%2$s<br><br>%3$s',
		__( 'Welcome to LifterLMS 5.0!', 'lifterlms' ),
		__( 'This new version of LifterLMS brings you the power to build and customize your student information forms using a simple point and click interface constructed on top of the WordPress block editor. Customization like the removal of default fields, changing the text of field labels, or reordering fields within a form is all possible without any code or professional help.', 'lifterlms' ),
		sprintf(
			// Translators: %1$s = Opening anchor tag to Forms admin page; %2$s = Closing anchor tag.
			__( '%1$sGet Started%2$s', 'lifterlms' ),
			'<a class="button-primary" href="' . esc_url( $get_started_link ) . '" >',
			'</a>'
		) . ' ' .
		sprintf(
			// Translators: %1$s = Opening anchor tag to the welcome blog post on lifterlms.com; %2$s = Closing anchor tag.
			__( '%1$sRead More%2$s', 'lifterlms' ),
			'<a class="button" href="https://blog.lifterlms.com/5-0/" target="_blank" rel="noopener">',
			'</a>'
		)
	);

	LLMS_Admin_Notices::add_notice(
		$notice_id,
		$html,
		array(
			'type'             => 'success',
			'dismiss_for_days' => 0,
			'remindable'       => false,
		)
	);
	return false;
}


Top ↑

Changelog Changelog

Changelog
Version Description
5.0.0 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

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