This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*MIME TYPE*/ | |
function wpufe_custom_upload_extensions( $extensions ) { | |
$extensions['custom'] = array( | |
'label' => __( 'Custom Extensions', 'wpuf' ), | |
'ext' => 'eps,ai', | |
); | |
return $extensions; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_action( 'wp_ajax_dokan_fetch_product_child_category', 'dokan_fetch_product_child_category' ); | |
function dokan_fetch_product_child_category() { | |
if ( ! isset( $_REQUEST['_wpnonce'] ) || ! wp_verify_nonce( $_REQUEST['_wpnonce'], 'marketica-child-theme-nonce' ) ) { | |
wp_send_json_error( __( 'Nonce Verfication faild', 'dokan' ) ); | |
} | |
$category_id = ( isset( $_POST['category'] ) && ! empty( $_POST['category'] ) ) ? $_POST['category'] : ''; | |
if ( empty( $category_id ) ) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_action( 'dokan_seller_meta_fields', 'dokan_load_store_seo_field_in_admin', 10 ); | |
add_action( 'dokan_process_seller_meta_fields', 'dokan_process_seller_seo_data', 10 ); | |
function dokan_load_store_seo_field_in_admin( $user ) { | |
$seo = new Dokan_Pro_Store_Seo(); | |
$seller_profile = dokan_get_store_info( $user->ID ); | |
$seo_meta = isset( $seller_profile['store_seo'] ) ? $seller_profile['store_seo'] : array(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_action( 'wp_enqueue_scripts', 'flatsome_child_live_search_script', 78 ); | |
function flatsome_child_live_search_script() { | |
global $wp, $extensions_uri; | |
if ( isset( $wp->query_vars['settings'] ) && $wp->query_vars['settings'] == 'store' ) { | |
wp_dequeue_script( 'jquery-ui-autocomplete' ); | |
wp_dequeue_script( 'flatsome-live-search' ); | |
wp_dequeue_script( 'dokan-tag-it' ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function _mygd_dequeue_script() { | |
if(!function_exists('geodir_plugin_url')){return;} | |
wp_deregister_script( 'chosen' ); | |
wp_register_script('chosen', geodir_plugin_url() . '/geodirectory-assets/js/chosen.jquery.min.js', array(), GEODIRECTORY_VERSION); | |
wp_dequeue_style( 'dokan-chosen-style' ); | |
} | |
add_action( 'wp_print_scripts', '_mygd_dequeue_script', 100 ); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.dokan-dashboard .dokan-dash-sidebar ul.dokan-dashboard-menu li.active, | |
.dokan-dashboard .dokan-dash-sidebar ul.dokan-dashboard-menu li:hover, | |
.dokan-dashboard .dokan-dash-sidebar ul.dokan-dashboard-menu li.dokan-common-links a:hover{ | |
background: #6abb46; | |
} | |
input[type="submit"].dokan-btn-theme, a.dokan-btn-theme, .dokan-btn-theme, | |
input[type="submit"].dokan-btn-theme:hover, | |
a.dokan-btn-theme:hover, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Showing the extra field on the registration form */ | |
add_action('register_form', 'new_register_field'); | |
function new_register_field() { | |
?> | |
<p> | |
<label for="first_name"><?php _e('First Name') ?><br /> | |
<input type="text" name="first_name" id="first_name" class="input" value="<?php echo esc_attr($_POST['first_name']); ?>" size="25" tabindex="20" /> | |
</label> | |
</p> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Add this actions | |
add_action( 'user_new_form', 'add_seller_store_field', 10 ); | |
add_action( 'edit_user_created_user', 'add_shop_url_for_seller' , 10, 2); | |
// Add this filter | |
add_filter( 'user_profile_update_errors', 'check_fields_add_new_user', 10, 3 ); | |
function add_shop_url_for_seller( $user_id, $notify ) { | |
if ( ! $user_id ) { | |
return; | |
} |