LLMS_Abstract_Integration::plugin_action_links( string[] $links, string $file, array $data, string $context )

Add plugin settings Action Links


Parameters Parameters

$links

(string[]) (Required) Existing action links.

$file

(string) (Required) Path to the plugin file, relative to the plugin directory.

$data

(array) (Required) Plugin data.

$context

(string) (Required) Plugin's content (eg: active, invactive, etc...).


Top ↑

Return Return

(string[])


Top ↑

Source Source

File: includes/abstracts/llms.abstract.integration.php

	public function plugin_action_links( $links, $file, $data, $context ) {

		$url = add_query_arg(
			array(
				'page'    => 'llms-settings',
				'tab'     => 'integrations',
				'section' => $this->id,
			),
			admin_url( 'admin.php' )
		);

		$links[] = '<a href="' . esc_url( $url ) . '">' . _x( 'Settings', 'Link text for integration plugin settings', 'lifterlms' ) . '</a>';

		return $links;

	}

Top ↑

Changelog Changelog

Changelog
Version Description
4.21.0 Don't check $context. If the plugin isn't active this won't run anyway so it's a useless check.
3.37.9 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

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