BUDDYC_PLUGIN_DIR
public
mixed
BUDDYC_PLUGIN_DIR
= plugin_dir_path(__FILE__)
public
mixed
BUDDYC_PLUGIN_DIR
= plugin_dir_path(__FILE__)
public
mixed
BUDDYC_PLUGIN_FILE
= __FILE__
public
mixed
BUDDYC_PLUGIN_NAME
= 'BuddyClients Free'
public
mixed
BUDDYC_PLUGIN_URL
= plugin_dir_url(__FILE__)
public
mixed
BUDDYC_PLUGIN_VERSION
= '1.0.29'
public
mixed
BUDDYC_URL
= 'https://buddyclients.com'
public
mixed
BUDDYC_VENDOR_DIR
= BUDDYC_PLUGIN_DIR . 'vendor'
Checks for admin table filter form submission.
buddyc_admin_filter_submission() : mixed
Admin icons.
Use buddyc_icon.
buddyc_admin_icon(string $icon) : string
Icon key.
HTML-formatted icon.
Initializes the AdminInfo class.
buddyc_admin_info(mixed $active_tab) : mixed
Dismisses admin tips.
buddyc_dismiss_admin_tips() : mixed
Builds an admin notice.
buddyc_admin_notice(array<string|int, mixed> $args) : mixed
{ An array of arguments for building the admin notice.
@type string $repair_link The link to the repair page.
@type string $repair_link_text Optional. The link text.
Defaults to 'Repair'.
@type string $message The message to display in the notice.
@type bool $dismissable Optional. Whether the notice should be dismissable.
Defaults to false.
@type string $color Optional. The color of the notice.
Accepts 'green', 'blue', 'orange', 'red'.
Defaults to blue.
}
Builds the ID for the admin notice.
buddyc_admin_notice_id(string $key) : mixed
The unique key for the admin notice.
Checks whether an admin notice is dimissed.
buddyc_admin_notice_dismissed(string $key) : mixed
The key of the notice.
Dismisses an admin notice.
buddyc_dismiss_admin_notice() : mixed
Outputs an admin table.
buddyc_admin_table(string $key) : mixed
The table key.
Adds a preview column to the brief type taxonomy.
buddyc_add_preview_column(array<string|int, mixed> $columns) : array<string|int, mixed>
The array of columns data.
The modified array of columns data.
Populates the new column with preview buttons.
buddyc_render_preview_button(string $content, string $column_name, int $term_id) : string
The content of the column.
The name of the column.
The ID of the term.
The modified content of the column.
Handles the preview request by redirecting to the preview.
buddyc_handle_preview_request() : mixed
Creates a draft post for preview based on the taxonomy term ID.
buddyc_create_preview_draft(int $taxonomy_term_id) : int|false
The taxonomy term ID.
The post ID of the draft, or false on failure.
Redirects to the draft post for preview.
buddyc_redirect_to_preview(int $taxonomy_term_id) : mixed
The taxonomy term ID.
Deletes draft brief preview posts.
buddyc_delete_brief_preview_drafts() : mixed
Runs draft deletion before the main query is executed on the buddyc_brief archive page.
buddyc_check_and_run_draft_deletion(WP_Query $query) : mixed
The WP_Query instance (passed by reference).
Initializes VersionCache.
buddyc_version_cache() : mixed
Builds the bookings overview content.
buddyc_bookings_dashboard() : mixed
The callback for the top-level menu.
buddyc_dashboard_content() : mixed
Handles booking actions (delete/update).
buddyc_handle_booking_action() : mixed
Flush permalinks
buddyc_flush_permalinks() : mixed
Checks if we're on a gutenberg page.
buddyc_gutenberg_editor() : bool
Generates an options array.
buddyc_options(string $key[, array<string|int, mixed> $args = null ]) : mixed
The key denoting which options to generate. Accepts 'clients', 'team', 'affiliates', 'users', 'projects'
Optional. An array of args to pass to the callback.
Handle create page button clicks.
buddyc_create_plugin_page() : mixed
Initializes the links added to the plugin page.
buddyc_plugin_page_links() : mixed
Initializes the upgrade page.
buddyc_init_upgrade() : mixed
Initializes the WelcomeMessage.
buddyc_init_welcome_message() : mixed
Builds array of all Xprofile filter field options.
buddyc_xprofile_filter_options() : mixed
Returns the one true BuddyClients Instance.
buddyclients_free() : BuddyClients|null
The one true BuddyClients Instance.
Displays an admin notice if multiple versions of BuddyClients are installed.
buddyc_installed_notice() : mixed
Displays an admin notice when BuddyPress is missing.
buddyc_missing_bp_notice_free() : mixed
Displays an admin notice when groups are not enabled.
buddyc_groups_disabled_notice_free() : mixed
Deletes all Payments associated with a BookingIntent.
buddyc_delete_booking_intent_payments(int $booking_intent_id) : mixed
The ID of the BookingIntent.
Deletes all BookedServices associated with a BookingIntent.
buddyc_delete_booking_intent_booked_services(int $booking_intent_id) : mixed
The ID of the BookingIntent.
Retrieves all BookedServices for a specific property.
buddyc_get_booked_services_by(string $property, mixed $value) : mixed
The property to search by.
The value to filter by.
Retrieves all BookedService objects.
buddyc_get_all_booked_services() : mixed
Retrieves all Payment objects.
buddyc_get_all_payments() : mixed
Updates payment status to eligible.
buddyc_payment_eligible(int $payment_id, string $cancellation_window, string $time_scheduled) : mixed
The ID of the Payment.
The cancellation window setting at the time of scheduling.
The time the function was scheduled.
Checks if all services for a booking intent are complete.
buddyc_check_booking_status(BookedService $booked_service) : mixed
The last updated BookedService object.
Retrieves a BookingIntent object.
buddyc_get_booking_intent(int $booking_intent_id) : mixed
The ID of the BookingIntent to retrieve.
Retrieves all BookingIntent objects.
buddyc_get_all_booking_intents() : mixed
Updates a BookingIntent object.
buddyc_update_booking_intent(int $ID, string $property, mixed $value) : mixed
The BookingIntent ID.
The property to update.
The new value for the property.
Retrieves the status of a BookingIntent.
buddyc_get_booking_intent_status(int $booking_intent_id) : mixed
The ID of the BookingIntent to retrieve.
Retrieves the IDs of the associated BookingPayments.
buddyc_get_booking_intent_payment_ids(int $booking_intent_id) : mixed
The ID of the BookingIntent.
Checks whether to send an abandoned booking email.
buddyc_abandoned_booking_check(int $booking_intent_id) : mixed
The ID of the BookingIntent to check.
Updates the BookingIntent when all services are complete.
buddyc_booking_intent_services_complete(int $booking_intent_id[, bool $services_complete = true ]) : BookingIntent
The ID of the BookingIntent to update.
Optional. Whether all services are complete. Defaults to true.
The updated BookingIntent object.
Checks whether deposits are enabled.
buddyc_deposits_enabled() : bool
True if deposits are enabled, false if not.
Retrieves a BookingPayment by ID.
buddyc_get_booking_payment(int $payment_id) : BookingPayment
The ID of the BookingPayment.
The BookingPayment object.
Updates a single property of a BookingPayment.
buddyc_update_booking_payment(int $ID, string $property, mixed $value) : mixed
The BookingPayment ID.
The property to update.
The new value for the property.
Updates a single property of multiple BookingPayment objects.
buddyc_update_booking_payments(array<string|int, mixed> $payment_ids, string $property, mixed $value) : mixed
The BookingPayment IDs.
The property to update.
The new value for the property.
Creates a new BookingPayment.
buddyc_new_booking_payment(BookingIntent $booking_intent, string $type) : mixed
The BookingIntent object.
The type of BookingPayment to create. Accepts 'deposit' and 'final'.
Returns the ID of a new BookingPayment.
buddyc_new_booking_payment_id(BookingIntent $booking_intent, string $type) : mixed
The BookingIntent object.
The type of BookingPayment to create. Accepts 'deposit' and 'final'.
Builds the url where clients can pay the fee.
buddyc_build_pay_link(int $payment_id[, int $booking_intent_id = null ]) : string
The ID of the BookingPayment.
Optional. The ID of the BookingIntent.
The url to pay.
Builds an array of data for the open BookingPayments for a single BookingIntent.
buddyc_get_unpaid_payment_data(int $booking_intent_id) : array<string|int, mixed>
The ID of the BookingIntent.
{ An array of data for unpaid payments for the BookingIntent.
@type string $pay_link The url to submit payment.
@type string $type The type of payment (final or deposit).
@type string $type_label The formatted label for the type.
@type float $amount The amount of the payment.
@status string $status The status of the payment (paid or unpaid).
}
Retrieves the status of the BookingIntent attached to a BookingPayment.
buddyc_get_payment_booking_status(int $payment_id) : mixed
The ID of the BookingPayment.
Retrieves all active BookingPayment objects.
buddyc_get_all_active_payments() : mixed
Active BookingPayment objects are attached to a succeeded BookingIntent.
Deletes all BookingPayment objects associated with a BookingIntent.
buddyc_delete_booking_intent_booking_payments(int $booking_intent_id) : mixed
The ID of the BookingIntent.
Updates a BookingPayment on successful Stripe payment.
buddyc_succeed_booking_payment(PaymentIntent $payment_intent) : mixed
The PaymentIntent from Stripe.
Marks a BookingPayment as due.
buddyc_booking_payments_due(int $booking_intent_id[, bool $due = true ]) : mixed
The ID of the BookingIntent.
Optional. Whether the BookingPayments should be marked as due. Defaults to true.
Unsucceeds a BookingPayment. Used manually in the admin area.
buddyc_unsucceed_booking_payment(mixed $payment_id) : mixed
Handles booking actions (delete/update).
buddyc_handle_booking_payment_action() : mixed
Handles AJAX calls to create line items.
buddyc_create_line_item() : mixed
Handles AJAX calls to retrieve project data.
buddyc_get_project() : mixed
Handles a successful booking event.
buddyc_booking_success(int $booking_intent_id[, string $status = 'succeeded' ]) : mixed
The ID of the successful BookingIntent.
Optional. The new status for the BookingIntent. Defaults to 'succeeded'.
Handles a successful payment event.
buddyc_payment_success([int $booking_payment_id = null ][, PaymentIntent $payment_intent = null ]) : mixed
The ID of the BookingPayment.
Optional. The Stripe PaymentIntent.
Handles AJAX calls to check team filter matches.
buddyc_team_filter_match() : bool
Whether the filters match.
Generates a help link describing the team selection process.
buddyc_team_select_help() : mixed
Generates an admin notice for the email log.
buddyc_email_log_admin_notice() : mixed
Defines email hooks.
buddyc_email_hooks() : mixed
Checks whether a certain email is enabled.
buddyc_email_enabled(string $key) : bool
The email key.
True if enabled, false if not.
Retrieves an Email object by ID.
buddyc_get_email(int $email_id) : mixed
The ID of the Email.
Retrieves all Email objects.
buddyc_get_all_emails() : mixed
Retrieves the cached value or a new instance of a service component class.
buddyc_get_service_cache(mixed $class_key, mixed $post_id) : mixed
Clears the cache on post updates.
buddyc_clear_service_cache_on_update(mixed $post_id, mixed $post) : mixed
Retrieves the current number of AdjustmentOptions attached to an Adjustment.
buddyc_adjustment_option_count(int $ID) : mixed
The ID of the Adjustment.
Retrieves a cached value from the preferred caching method.
buddyc_cache_get(string $key[, string $group = 'default' ][, string $type = 'wp_cache' ]) : mixed
The cache key.
Optional. Cache group for wp_cache. Default is 'default'.
Optional. Cache type: 'wp_cache', 'transient', or 'option'. Default is 'wp_cache'.
Cached value or false if not found.
Stores a value in the cache.
buddyc_cache_set(string $key, mixed $value[, int $expires = HOUR_IN_SECONDS ][, string $group = 'default' ][, string $type = 'wp_cache' ]) : bool
The cache key.
The value to store.
Expiration time in seconds. Default is 1 hour.
Optional. Cache group for wp_cache.
Optional. Cache type: 'wp_cache', 'transient', or 'option'. Default is 'wp_cache'.
True on success, false on failure.
Deletes a cached value.
buddyc_cache_delete(string $key[, string $group = 'default' ][, string $type = 'wp_cache' ]) : bool
The cache key.
Optional. Cache group for wp_cache.
Optional. Cache type: 'wp_cache', 'transient', or 'option'. Default is 'wp_cache'.
True on success, false on failure.
Clears all cached values belonging to this plugin (transients, options, and wp_cache).
buddyc_cache_clear_all() : mixed
Initializes the LicenseHandler.
buddyc_license_handler() : mixed
Retrieves the license from the LicenseHandler.
buddyc_get_license() : mixed
Retrieves the product from the LicenseHandler.
buddyc_get_product() : mixed
Defines allowed html for forms.
buddyc_allowed_html_form() : mixed
Adds safe styles to the Wordpress list.
buddyc_update_safe_styles() : mixed
Defines allowed html for forms with signature script.
buddyc_allowed_html_signature() : mixed
Ensures the htaccess domain is up to date.
buddyc_check_htaccess() : mixed
Initializes Cleanup manager.
buddyc_init_cleanup() : mixed
Handles switch between BuddyClients and BuddyClients Free.
buddyc_handle_version_switch() : mixed
Handles an update to a new BuddyClients version.
buddyc_handle_version_update() : mixed
Outputs a front end alert.
buddyc_alert(string $content[, int|null $priority = null ]) : mixed
The content to display.
Optional. The priority of the alert.
Outputs the testimonials archive from a shortcode.
buddyc_testimonials_shortcode(mixed $atts) : mixed
Outputs the archive from a shortcode.
buddyc_build_archive(string $post_type[, array<string|int, mixed> $args = [] ]) : mixed
The slug of the post type.
{ An optional array of args.
@type string $tags An associative array of tags to filter by.
}
Defines component names.
buddyc_components_map() : mixed
Retrieves translatable component name.
buddyc_component_name(string $component) : mixed
The component.
Generates a contact message based on provided settings.
buddyc_contact_message([bool $site_name = false ][, bool $lowercase = false ]) : mixed
Whether to include the site name. Defaults to false and uses 'us'.
Whether to format as lowercase. Defaults to formatting as full sentence.
Generates a copy to clipboard field.
buddyc_copy_to_clipboard(string $content[, bool $input = true ]) : mixed
The content to copy.
Optional. Whether to generate an input field. Defaults to true.
Handle create account form submission.
buddyc_checkout_create_account() : mixed
Called by AJAX script.
Validates password strength.
buddyc_validate_password_strength(string $password) : string|null
Checks if the password meets strength requirements.
The password to validate.
Returns error message if validation fails, otherwise null.
Generates login name.
buddyc_generate_login_name(mixed $first_name) : mixed
Checks against existing users to ensure unique handle.
Generates file download links.
buddyc_download_links(array<string|int, mixed> $file_ids[, bool $show_file_name = false ]) : mixed
An array of file IDs.
Optional. Whether to display the file name. Defaults to false.
Generates list of file names.
buddyc_file_names(array<string|int, mixed> $file_ids[, bool $comma_separated = false ]) : mixed
An array of file IDs.
Optional. Whether to display the file names as a comma separated list or with line breaks. Defaults to false.
Initializes email triggers.
buddyc_email_triggers() : mixed
Sets featured image for a post.
buddyc_set_featured_image(int $post_id, File $file) : mixed
The ID of the post.
The File object.
Retrieves the upload ID of a File.
buddyc_get_file_upload_id(int $file_id) : mixed
The ID of the File.
Generates a new FileHandler instance.
buddyc_file_handler(mixed $files, array<string|int, mixed> $args) : mixed
{ Array of arguments for File creation.
@type bool $temporary Whether the files are temporary.
@type ?int $user_id File owner ID.
@type ?int $project_id Associated project ID.
}
Initializes the File ObjectHandler.
buddyc_file_object_handler() : mixed
Generates a new Form.
buddyc_build_form(array<string|int, mixed> $args) : mixed
{ An array of arguments to create the form.
@type string $key The form key.
@type callable $fields_callback The callback to generate the form fields.
@type string $submission_class The class that handles the form submission.
@type bool $submit_button Optional. Whether to include a submit button.
@type string $submit_text Optional. The text of the submit button.
Defaults to 'Submit'.
@type string $submit_classes Optional. Classes to apply to the submit button.
@type array $values Optional. A keyed array of values to populate the form fields.
@type int $avatar Optional. Creates a user avatar above the form.
@type string $form_classes Optional. Classes to apply to the form.
}
Generates a new Form.
buddyc_echo_form(array<string|int, mixed> $args) : mixed
{ An array of arguments to create the form.
@type string $key The form key.
@type callable $fields_callback The callback to generate the form fields.
@type string $submission_class The class that handles the form submission.
@type bool $submit_button Optional. Whether to include a submit button.
@type string $submit_text Optional. The text of the submit button.
Defaults to 'Submit'.
@type string $submit_classes Optional. Classes to apply to the submit button.
@type array $values Optional. A keyed array of values to populate the form fields.
@type int $avatar Optional. Creates a user avatar above the form.
@type string $form_classes Optional. Classes to apply to the form.
}
Checks for Freelancer Mode.
buddyc_freelancer_mode() : mixed
Retrieves the Freelancer ID.
buddyc_freelancer_id() : mixed
Retrieves the current url.
buddyc_curr_url() : string
The current url, or an empty string on failure.
Clips content by word count.
buddyc_truncate_content(string $content, int $word_count) : string
Content to truncate.
Number of words.
$content Truncated content.
Clips content by character count.
buddyc_truncate_content_by_char(string $content, int $char_count) : string
Content to truncate.
Number of characters.
$content Truncated content.
Formats status value for display.
buddyc_format_status(string $value[, mixed $add_class = null ]) : mixed
The value to format.
Checks whether a time has passed.
buddyc_time_has_passed(string|int $target_time) : bool
The time to check.
True if the time has passed, false if not.
Converts a hex code to rgba.
buddyc_hex_to_rgba(string $hex[, int $alpha = 0.6 ]) : mixed
The hex code to convert.
Optional. The alpha value for transparency. Defaults to 0.6.
Outputs a javascript alert.
buddyc_js_alert(string $message[, bool $admin = false ]) : mixed
The alert text.
Optional. Whether to also apply the script to the admin area. Defaults to false (i.e., front end).
Adds inline styles to the front end.
buddyc_inline_style(string $css[, bool $admin = false ]) : mixed
The CSS to add.
Optional. Whether to also apply the styles to the admin area. Defaults to false.
Note: This function should be called on a hook that runs before wp_enqueue_scripts
,
such as init
, to ensure the styles are properly enqueued and applied.
Adds inline scripts to the front end or admin area.
buddyc_inline_script(string $script[, bool $admin = false ][, bool $direct = false ]) : mixed
The JavaScript to add.
Optional. Whether to also apply the script to the admin area. Defaults to false (i.e., front end).
Optional. Whether to call the inline script function immediately, as opposed to using a hook. Defaults to false.
Outputs an html-formatted group link.
buddyc_group_link(int $group_id) : mixed
The ID of the group.
Outputs the group name.
buddyc_group_name(int $group_id) : mixed
The ID of the group.
Handles AJAX calls to update BookingIntent with newly entered email.
buddyc_update_booking_intent_email() : mixed
Initializes an instance of the ObjectHandler class.
buddyc_object_handler(string $class) : mixed
The fully qualified class name.
Retrieves all items of a class.
buddyc_get_all_objects(string $class) : mixed
The fully qualified class name.
Creates a new ParamManager instance.
buddyc_param_manager([string $url = null ]) : mixed
Optional. The url to modify. Defaults to the current url.
Retrieves the value of a url parameter.
buddyc_get_param(string $param[, string $url = null ]) : mixed
The key of the parameter to retrieve.
Optional. The url to modify. Defaults to the current url.
Retrieves all url parameters.
buddyc_get_all_params([string $url = null ]) : array<string|int, mixed>
Optional. The url to modify. Defaults to the current url.
An associative array of all url parameters.
Retrieves all url parameters.
buddyc_add_params(array<string|int, mixed> $params[, string $url = null ]) : string
An associative array of params and values.
Optional. The url to modify. Defaults to the current url.
The new url.
Removes a url parameter.
buddyc_remove_param(string $param[, string $url = null ]) : string
The param to remove.
Optional. The url to modify. Defaults to the current url.
The new url.
Removes all url parameters.
buddyc_strip_params([string $url = null ]) : string
Optional. The url to modify. Defaults to the current url.
The new url.
Generates a new PDF instance.
buddyc_pdf([int $ID = null ]) : mixed
Optional. The ID of the PDF.
Generates a new PDF.
buddyc_create_pdf(array<string|int, mixed> $args) : int
{ An array of arguments for generating the PDF content.
@int $user_id Optional. The user to whom the PDF belongs.
@string $type The type of PDF document.
@string $title The title of the PDF document.
@string $content The primary content to include in the PDF.
@array $items Optional. An array of strings to append to the document.
@string $image_path Optional. The file path to an image to include.
}
The ID of the newly created PDF.
Includes the TCPDF library.
buddyc_tcpdf_library() : mixed
Generates a PDF download link.
buddyc_pdf_download_link(int $pdf_id) : mixed
The ID of the PDF file.
Retrieves help doc content.
buddyc_get_popup_content() : mixed
AJAX callback.
Outputs a popup link.
buddyc_help_link([int $post_id = null ][, string $link_text = null ][, string $url = null ][, mixed $raw_content = null ]) : mixed
The ID of the post from which to retrieve the content.
Optional. The text to display. Defaults to ? icon.
Optional. The full url of the page to display.
Manually outputs a popup.
buddyc_output_popup(mixed $content) : mixed
string The content of the popup.
Updates popup content.
buddyc_update_popup(mixed $content) : mixed
string The content of the popup.
Initializes the overlay.
buddyc_init_overlay() : mixed
Performs a post query.
buddyc_post_query(string $post_type[, array<string|int, mixed> $args = [] ]) : mixed
The slug of the post type.
} An optional array of args for the post query.
@array array $meta An associative array of meta keys and values.
@string string $compare The compare operator for the meta queries.
Defaults to '='.
@array array $tax An associative arary of tax names and tags.
@int int $max The maximum number of posts to retrieve.
}
Generates a link to a user's profile.
buddyc_profile_link([array<string|int, mixed> $args = null ]) : mixed
{ An array of arguments to build the link.
@int $user_id Optional. The ID of the user.
@string $slug Optional. The slug to append to the profile link.
}
Retrieves profile extension link.
buddyc_profile_ext_link(mixed $key[, int $user_id = null ]) : string
Optional. The ID of the user. Defaults to current user.
The url to the profile extension tab.
Enqueues the Google reCAPTCHA script.
buddyc_enqueue_recaptcha_script() : mixed
Fetches the reCAPTCHA site key.
buddyc_recaptcha_site_key() : mixed
Fetches the reCAPTCHA secret key.
buddyc_recaptcha_secret_key() : mixed
Checks that the reCAPTCHA keys exist and reCAPTCHA is enabled.
buddyc_recaptcha_enabled() : mixed
Fetches the reCAPTCHA threhold setting.
buddyc_recaptcha_threshold() : mixed
Defaults to 0.5 (0 most suspicous, 1.0 least suspicious).
Retrieves the ID of a reference post by key.
buddyc_get_reference_post_id(string $key) : mixed
The key of the post ID to retrieve.
Adds a new reference post.
buddyc_add_reference_post(string $key, array<string|int, mixed> $args) : mixed
The unique key for the reference post.
{ An array of arguments for creating the new reference post.
@string $content The content of the post.
@string $title The title of the post.
}
Retrieves the CTA button text from settings.
buddyc_cta_btn_text() : mixed
Retrieves the CTA button url from settings.
buddyc_cta_btn_url() : mixed
Checks if the CTA button is enabledin settings.
buddyc_enable_cta_btn() : mixed
Builds the array of info for localizing the header button script.
buddyc_header_btn_info() : mixed
Initializes the Scheduler.
buddyc_init_scheduler() : mixed
Schedules a new event.
buddyc_schedule(array<string|int, mixed> $args) : mixed
{ An array of args to construct the scheduled event.
@param string $event_key The event key.
@param string $timeout The timeout timestamp.
@param array $args Optional. An array of args to pass to the callback.
Defaults to empty array.
@param string|int $identifier Optional. An identifier to prevent duplicate events.
}
Checks whether any valid services exist.
buddyc_services_exist() : bool
True if services exist, false if not.
Retrieves the adjustment options for an adjustment post.
buddyc_adjustment_options(mixed $post_id) : mixed
Retrieves the number of adjustment options for an adjustment post.
buddyc_adjustment_options_count(mixed $post_id) : mixed
Retrieves the value of plugin settings.
buddyc_get_setting(string $settings_group[, string $settings_key = null ]) : mixed
The settings group to retrieve.
Optional. The specific setting to retrieve.
Retrieves the value of plugin settings.
buddyc_update_setting(string $settings_group, string $settings_key, mixed $value) : mixed
The settings group.
The specific setting field.
The value to set.
Retrieves an array of help post type slugs.
buddyc_help_post_types() : mixed
Retrieves colors from settings.
buddyc_color(string $type) : mixed
The color type to retrieve. Accepts 'primary', 'accent', and 'tertiary'.
Retrieves the permalink to a page defined in the plugin settings.
buddyc_get_page_link(string $page_key[, bool $return_link = true ]) : int|string
The key of the page to retrieve.
Optional. Whether to return the link or the page ID. Defaults to true and returns permalink.
The permalink or the page ID.
Retrieves the array of shortcodes data.
buddyc_shortcodes_data() : array<string|int, mixed>
An associative array of shortcode names and data.
Retrieves the shortcode by key.
buddyc_get_shortcode(string $key) : mixed
The shortcode key.
Checks whether a shortcode is present in the page content.
buddyc_shortcode_exists(string $shortcode_key) : bool
The shortcode key.
True if the shortcode exists on the page, false if not.
Checks whether any plugin shortcode is present in the page content.
buddyc_any_shortcode_exists() : bool
True if any shortcode exists on the page, false if not.
Generates button html.
buddyc_btn(array<string|int, mixed> $args) : mixed
An array of arguments.
@type string $text The button text. Defaults to 'Learn More'. @type string $link The button url. @type string $style The type of style for the button. Accepts 'primary', 'secondary', 'outline'. Defaults to 'primary'. @type string $size Optional. The size of button. Accepts 'small', 'medium', 'large', 'wide'. Defaults to 'medium'.
Check for BuddyBoss theme.
buddyc_buddyboss_theme() : bool
Outputs icon html.
buddyc_icon(string $key[, string $color = null ]) : string
The identifying key of the icon.
Optional. The color of the icon. Accepts 'blue', 'black', 'green', 'red', or 'gray'.
The icon html.
Outputs a string of icon classes
buddyc_icon_class(string $key[, string $color = null ]) : string
The identifying key of the icon.
Optional. The color of the icon. Accepts 'blue', 'black', 'green', 'red', or 'gray'.
The string of icon classes.
Checks whether the active theme is a Wordpress default theme.
buddyc_is_wp_theme() : bool
True if the active theme is a WP theme.
Initializes TemplateManager.
init_template_manager() : mixed
Check if user is a team member.
buddyc_is_team([mixed $user_id = null ]) : str|bool
(optional. defaults to current user.)
$member_type or false
Check if user is a client.
buddyc_is_client([mixed $user_id = null ]) : str|bool
(optional. defaults to current user.)
$member_type or false
Check if user is a site admin.
buddyc_is_admin([mixed $user_id = null ]) : bool
(optional. defaults to current user.)
Get site admin id.
buddyc_admin_id() : mixed
Get all team members.
buddyc_all_team() : mixed
Get all clients.
buddyc_all_clients() : mixed
Retrieves member types.
buddyc_member_types([string $type = null ]) : array<string|int, mixed>
The type of member types to return. Accepts 'client', 'team', 'sales'.
Associative array of member type names and labels.
Retrieves all xprofile fields.
buddyc_all_xprofile() : mixed
Initializes FilterField class on post updates.
buddyc_update_filter_field(int $post_id) : mixed
The ID of the post being saved.
Retrieves Roles field ID.
buddyc_roles_field_id() : mixed
Creates or updates roles field if necessary.
Builds array of options for roles xprofile field.
buddyc_roles_options(mixed $post_type) : mixed
Initializes XprofileManager.
buddyc_xprofile_manager() : mixed
Allows team to self-select roles.
buddyc_show_role_xprofile() : mixed
Hides or shows edit option based on setting.
Disallows manual updates to the roles field.
buddyc_no_roles_updates() : mixed