LLMS_SendWP::get_connect_setting()

Get the “Connect” Setting field html.


Return Return

(string)


Top ↑

Source Source

File: includes/admin/class-llms-sendwp.php

	protected function get_connect_setting() {

		if ( $this->is_connected() ) {

			$ret = array(
				__( 'Your site is connected to SendWP.', 'lifterlms' ),
			);

			if ( function_exists( 'sendwp_forwarding_enabled' ) && sendwp_forwarding_enabled() ) {
				$ret[] = sprintf(
					// Translators: %1$s = Opening anchor tag; %2$s = Closing anchor tag.
					__( '%1$sManage your account%2$s.', 'lifterlms' ),
					'<a href="https://app.sendwp.com/dashboard" target="_blank" rel="noopener noreferrer">',
					'</a>'
				);
			} else {
				$ret[] = sprintf(
					// Translators: %1$s = Opening anchor tag; %2$s = Closing anchor tag.
					'<em>' . __( 'Email sending is currently disabled. %1$sVisit the SendWP Settings%2$s to enable sending..', 'lifterlms' ) . '</em>',
					'<a href="' . admin_url( '/tools.php?page=sendwp' ) . '">',
					'</a>'
				);
			}

			return '<p>' . implode( ' ', $ret ) . '</p>';

		}

		return '<button class="llms-button-outline" id="llms-sendwp-connect"><i class="fa fa-paper-plane-o" aria-hidden="true"></i> Connect SendWP</button>';

	}


Top ↑

Changelog Changelog

Changelog
Version Description
5.3.2 Update the URL for managing an account.
3.40.0 Abstract methods used to determine if SendWP is connected.
3.36.1 Introduced.

Top ↑

User Contributed Notes User Contributed Notes

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