'wc_facebook_sync_mode',
'label' => __( 'Facebook Sync', 'facebook-for-woocommerce' ),
'options' => array(
self::SYNC_MODE_SYNC_AND_SHOW => __( 'Sync and show in catalog', 'facebook-for-woocommerce' ),
self::SYNC_MODE_SYNC_AND_HIDE => __( 'Sync and hide in catalog', 'facebook-for-woocommerce' ),
self::SYNC_MODE_SYNC_DISABLED => __( 'Do not sync', 'facebook-for-woocommerce' ),
),
'value' => $sync_mode,
'desc_tip' => true,
'description' => __( 'Choose whether to sync this product to Facebook and, if synced, whether it should be visible in the catalog.', 'facebook-for-woocommerce' ),
)
);
?>
is_type( 'variable' ) ) {
// Render video field only for variable products
$this->render_facebook_product_video_field( $video_urls );
}
?>
';
echo '';
wp_editor(
$rich_text_description,
\WC_Facebookcommerce_Integration::FB_PRODUCT_DESCRIPTION,
array(
'id' => \WC_Facebook_Product::FB_PRODUCT_DESCRIPTION,
'textarea_name' => \WC_Facebookcommerce_Integration::FB_PRODUCT_DESCRIPTION,
'textarea_rows' => 10,
'media_buttons' => true,
'teeny' => true,
'quicktags' => false,
'tinymce' => array(
'toolbar1' => 'bold,italic,bullist,spellchecker,fullscreen',
),
)
);
echo '
';
woocommerce_wp_radio(
array(
'id' => 'fb_product_image_source',
'label' => __( 'Facebook Product Image', 'facebook-for-woocommerce' ),
'desc_tip' => true,
'description' => __( 'Choose the product image that should be synced to the Facebook catalog and displayed for this product.', 'facebook-for-woocommerce' ),
'options' => array(
Products::PRODUCT_IMAGE_SOURCE_PRODUCT => __( 'Use WooCommerce image', 'facebook-for-woocommerce' ),
Products::PRODUCT_IMAGE_SOURCE_CUSTOM => __( 'Use custom image', 'facebook-for-woocommerce' ),
),
'value' => $image_source ? $image_source : Products::PRODUCT_IMAGE_SOURCE_PRODUCT,
'class' => 'short enable-if-sync-enabled js-fb-product-image-source',
'wrapper_class' => 'fb-product-image-source-field',
)
);
woocommerce_wp_text_input(
array(
'id' => \WC_Facebook_Product::FB_PRODUCT_IMAGE,
'label' => __( 'Custom Image URL', 'facebook-for-woocommerce' ),
'value' => $image,
'class' => sprintf( 'enable-if-sync-enabled product-image-source-field show-if-product-image-source-%s', Products::PRODUCT_IMAGE_SOURCE_CUSTOM ),
'desc_tip' => true,
'description' => __( 'Please enter an absolute URL (e.g. https://domain.com/image.jpg).', 'facebook-for-woocommerce' ),
)
);
// Render the Facebook Product Video field at Product level
$this->render_facebook_product_video_field( $video_urls );
woocommerce_wp_text_input(
array(
'id' => \WC_Facebook_Product::FB_PRODUCT_PRICE,
'label' => sprintf(
/* translators: Placeholders %1$s - WC currency symbol */
__( 'Facebook Price (%1$s)', 'facebook-for-woocommerce' ),
get_woocommerce_currency_symbol()
),
'desc_tip' => true,
'description' => __( 'Custom price for product on Facebook. Please enter in monetary decimal (.) format without thousand separators and currency symbols. If blank, product price will be used.', 'facebook-for-woocommerce' ),
'cols' => 40,
'rows' => 60,
'value' => $price,
'class' => 'enable-if-sync-enabled',
)
);
woocommerce_wp_hidden_input(
array(
'id' => \WC_Facebook_Product::FB_REMOVE_FROM_SYNC,
'value' => '',
)
);
?>