/** * Remove widgets from the vendor store and single product pages conditionally. * * You will need the sidebar internal id (eg sidebar-1) * You will need the list of widget id’s you want to disable (eg woocommerce_layered_nav-2, meta-2)…Continue reading
/** * The template for displaying the shipping label * * Override this template by copying it to yourtheme/wc-vendors/dashboard/order * * @package WCVendors_Pro * @version 1.7.5 * @since 1.0.4 * * The following variables are available in this template *…Continue reading
/** * Add the Tax ID Field to the settings page * * In this example we are using ABN/ACN for Australian GST Invoices * You can update this tax label to whatever suits your requirements. */ add_action( ‘wcvendors_settings_before_company_url’, ‘wcv_add_tax_field’…Continue reading
/** * This will disable delete only for published products, leaving drafts to be able to be deleted * You would not need to disable delete in the WC Vendors Settings in WP Admin. */ add_filter( ‘wcv_product_table_row_actions’, ‘wcv_allow_delete_draft’, 10, 2…Continue reading
// Add the tab to the tab nav add_filter( ‘wcv_store_tabs’, ‘add_custom_tab_nav’ ); function add_custom_tab_nav( $tabs ){ // Target is the custom css id for the content tab in the code below this $tabs[‘custom_tab’] = array( ‘label’ => __( ‘Custom’, ‘wcvendors-pro’…Continue reading
// Add the fields to user edit screen. add_action( ‘show_user_profile’, ‘add_extra_user_fields’ ); add_action( ‘edit_user_profile’, ‘add_extra_user_fields’ ); function add_extra_user_fields( $user ){ // Document file URL. $document_file_url = ( $user->_wcv_custom_settings_doc_example ) ? wp_get_attachment_url( $user->_wcv_custom_settings_doc_example ) : ”; // Image file URL. $image_file_url…Continue reading
// Add the video field to the signup form. add_action( ‘wcv_form_input_after__wcv_store_name’, ‘wcv_video_uploader’); function wcv_video_uploader( ){ // Remove this check to have it show on sign up and settings pages. if (‘signup’ == WCVendors_Pro_Store_Form::$form_type ){ echo ‘ Video Uploader ‘; $value…Continue reading
// Add the audio field to the signup form. add_action( ‘wcv_form_input_after__wcv_store_name’, ‘wcv_audio_uploader’); function wcv_audio_uploader( ){ // Remove this check to have it show on sign up and settings pages. if (‘signup’ == WCVendors_Pro_Store_Form::$form_type ){ echo ‘ Audio Uploader ‘; $value…Continue reading
// Add the image field to the signup form. add_action( ‘wcv_form_input_after__wcv_store_name’, ‘wcv_image_uploader’); function wcv_image_uploader( ){ if (‘signup’ == WCVendors_Pro_Store_Form::$form_type ){ echo ‘ Image Uploader ‘; $value = get_user_meta( get_current_user_id(), ‘_wcv_custom_settings_image_example’, true ); WCVendors_Pro_Form_Helper::file_uploader( array( ‘id’ => ‘_wcv_custom_settings_image_example’, ‘header_text’ => __(‘Image…Continue reading
// Add the document field to the signup form. add_action( ‘wcv_form_input_after__wcv_store_name’, ‘wcv_doc_uploader’); function wcv_doc_uploader( ){ if (‘signup’ == WCVendors_Pro_Store_Form::$form_type ){ echo ‘ ‘; echo ‘ Document Uploader ‘; $value = get_user_meta( get_current_user_id(), ‘_wcv_custom_settings_doc_example’, true ); WCVendors_Pro_Form_Helper::file_uploader( array( ‘id’ => ‘_wcv_custom_settings_doc_example’,…Continue reading