brainstrom_product_name( int $product_id = '' )

Brainstorm product name.


Description


Parameters

$product_id

(int) (Optional) Product ID.

Default value: ''


Source

File: admin/bsf-core/index.php

	function brainstrom_product_name( $product_id = '' ) {
		$product_name        = '';
		$brainstrom_products = get_option( 'brainstrom_products', array() );

		foreach ( $brainstrom_products as $key => $value ) {
			foreach ( $value as $key => $product ) {
				if ( $product_id === $key ) {
					$product_name = isset( $product['product_name'] ) ? $product['product_name'] : '';
				}
			}
		}

		return $product_name;
	}


User Contributed Notes

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