SILENT KILLERPanel

Current Path: > home > transcarter > public_html > wp-content > plugins > leadin > > > public > admin


Operation   : Linux host59.registrar-servers.com 4.18.0-513.18.1.lve.2.el8.x86_64 #1 SMP Sat Mar 30 15:36:11 UTC 2024 x86_64
Software     : Apache
Server IP    : 198.54.126.42 | Your IP: 216.73.216.135
Domains      : 1034 Domain(s)
Permission   : [ 0755 ]

Files and Folders in: /home/transcarter/public_html/wp-content/plugins/leadin///public/admin

NameTypeSizeLast ModifiedActions
modules Directory - -
widgets Directory - -
class-adminconstants.php File 7415 bytes July 17 2025 21:06:25.
class-connection.php File 5403 bytes July 17 2025 21:06:25.
class-contentembedinstaller.php File 5054 bytes July 17 2025 21:06:25.
class-deactivationform.php File 3593 bytes July 17 2025 21:06:25.
class-gutenberg.php File 1243 bytes July 17 2025 21:06:25.
class-impact.php File 1045 bytes July 17 2025 21:06:25.
class-leadinadmin.php File 10491 bytes July 17 2025 21:06:25.
class-links.php File 6427 bytes July 17 2025 21:06:25.
class-menuconstants.php File 492 bytes July 17 2025 21:06:25.
class-noticemanager.php File 2246 bytes July 17 2025 21:06:25.
class-pluginactionsmanager.php File 1832 bytes July 17 2025 21:06:25.
class-reviewbanner.php File 3004 bytes July 17 2025 21:06:25.
class-reviewcontroller.php File 2234 bytes July 17 2025 21:06:25.
class-routing.php File 2636 bytes July 17 2025 21:06:25.

Reading File: /home/transcarter/public_html/wp-content/plugins/leadin///public/admin/class-routing.php

<?php

namespace Leadin\admin;

use Leadin\utils\QueryParameters;

/**
 * Class for helping route around the plugin in OAuth mode.
 */
class Routing {

	const EXPIRED        = 'leadin_expired';
	const JUST_CONNECTED = 'leadin_just_connected';
	const IS_NEW_PORTAL  = 'is_new_portal';
	const REDIRECT_NONCE = 'leadin_redirect';
	const REVIEW         = 'leadin_review';

	/**
	 * Redirect to the root of the leadin plugin with optional query parameters.
	 * Verified with a redirect nonce.
	 *
	 * @param string $page the WordPress page parameter to redirect to.
	 * @param array  $extra_params Associative array of parameters to add to the redirected URL.
	 */
	public static function redirect( $page, $extra_params = array() ) {
		$redirect_params = array_merge(
			array( 'page' => $page ),
			array( self::REDIRECT_NONCE => wp_create_nonce( self::REDIRECT_NONCE ) ),
			$extra_params
		);

		$redirect_url = add_query_arg(
			urlencode_deep( $redirect_params ),
			admin_url( 'admin.php' )
		);

		nocache_headers();
		wp_safe_redirect( $redirect_url );
		exit;
	}

	/**
	 * Return a boolean if the plugin has just been connected.
	 * Signified by query parameter flag `leadin_just_connected`.
	 *
	 * @return bool True if the plugin has just connected.
	 */
	public static function has_just_connected_with_oauth() {
		$just_connected_param = QueryParameters::get_param(
			self::JUST_CONNECTED,
			self::REDIRECT_NONCE,
			self::REDIRECT_NONCE
		);

		return null !== $just_connected_param;
	}

	/**
	 * Return a boolean if the plugin is being used with a new portal.
	 * Signified by query parameter flag `is_new_portal`.
	 *
	 * @return bool True if the plugin has just connected using a new portal.
	 */
	public static function is_new_portal_with_oauth() {
		$just_connected_param = QueryParameters::get_param(
			self::IS_NEW_PORTAL,
			self::REDIRECT_NONCE,
			self::REDIRECT_NONCE
		);

		return null !== $just_connected_param;
	}

	/**
	 * Reads query param to see if request has review request query params
	 *
	 * @return bool True if the `leadin_review` query parameter is not empty
	 */
	public static function has_review_request() {
		$is_review_request = QueryParameters::get_param(
			self::REVIEW,
			'leadin-review'
		);
		return ! empty( $is_review_request );
	}

	/**
	 * Reads query param to see if request has review request query params set to true
	 *
	 * @return bool True if the `leadin_review` query parameter is true
	 */
	public static function is_review_request() {
		$is_review_request = QueryParameters::get_param(
			self::REVIEW,
			'leadin-review'
		);
		return 'true' === $is_review_request;
	}


}

SILENT KILLER Tool