Constants

BARN2_URL

BARN2_URL = 'https://barn2.com'

EDD_STORE_URL

EDD_STORE_URL = 'https://barn2.com'

KNOWLEDGE_BASE_URL

KNOWLEDGE_BASE_URL = 'https://barn2.com'

Methods

barn2_link()

barn2_link(string  $relative_path, string  $link_text = '', boolean  $new_tab = false) : string

Formats a HTML link to a path on the Barn2 site.

Parameters

string $relative_path

The path relative to https://barn2.com.

string $link_text

The link text.

boolean $new_tab

Whether to open the link in a new tab.

Returns

string —

The hyperlink.

barn2_url()

barn2_url(  $relative_path) 

Parameters

$relative_path

format_barn2_link_open()

format_barn2_link_open(  $relative_path,   $new_tab = false) 

Parameters

$relative_path
$new_tab

format_link()

format_link(  $url,   $link_text,   $new_tab = false) 

Parameters

$url
$link_text
$new_tab

format_link_open()

format_link_open(  $url,   $new_tab = false) 

Parameters

$url
$new_tab

store_url()

store_url(  $relative_path) 

Parameters

$relative_path

format_store_link()

format_store_link(  $relative_path,   $link_text,   $new_tab = true) 

Parameters

$relative_path
$link_text
$new_tab

format_store_link_open()

format_store_link_open(  $relative_path,   $new_tab = true) 

Parameters

$relative_path
$new_tab

get_add_to_cart_url()

get_add_to_cart_url(  $download_id,   $price_id,   $discount_code = '') 

Parameters

$download_id
$price_id
$discount_code

is_admin()

is_admin() 

is_front_end()

is_front_end() 

is_woocommerce_active()

is_woocommerce_active() 

is_product_addons_active()

is_product_addons_active() 

is_edd_active()

is_edd_active() 

is_acf_active()

is_acf_active() 

is_protected_categories_active()

is_protected_categories_active() 

is_product_table_active()

is_product_table_active() 

is_quick_view_pro_active()

is_quick_view_pro_active() 

get_script_suffix()

get_script_suffix() 

register_services()

register_services(  $services) 

Parameters

$services

format_store_url()

format_store_url(  $relative_path) 

Parameters

$relative_path