Submit
Path:
~
/
home
/
getwphos
/
public_html
/
almajd14
/
wp-content
/
plugins
/
halstein-core
/
inc
/
roles
/
admin
/
File Content:
role-fields.php
<?php if ( ! function_exists( 'halstein_core_add_admin_user_options' ) ) { /** * Function that add global user options */ function halstein_core_add_admin_user_options() { $qode_framework = qode_framework_get_framework_root(); $roles_social_scope = apply_filters( 'halstein_core_filter_role_social_array', array( 'administrator', 'author' ) ); $page = $qode_framework->add_options_page( array( 'scope' => $roles_social_scope, 'type' => 'user', 'title' => esc_html__( 'Social Networks', 'halstein-core' ), 'slug' => 'admin-options', ) ); if ( $page ) { $page->add_field_element( array( 'field_type' => 'text', 'name' => 'qodef_user_facebook', 'title' => esc_html__( 'Facebook', 'halstein-core' ), 'description' => esc_html__( 'Enter user Facebook profile URL', 'halstein-core' ), ) ); $page->add_field_element( array( 'field_type' => 'text', 'name' => 'qodef_user_instagram', 'title' => esc_html__( 'Instagram', 'halstein-core' ), 'description' => esc_html__( 'Enter user Instagram profile URL', 'halstein-core' ), ) ); $page->add_field_element( array( 'field_type' => 'text', 'name' => 'qodef_user_twitter', 'title' => esc_html__( 'Twitter', 'halstein-core' ), 'description' => esc_html__( 'Enter user Twitter profile URL', 'halstein-core' ), ) ); $page->add_field_element( array( 'field_type' => 'text', 'name' => 'qodef_user_linkedin', 'title' => esc_html__( 'LinkedIn', 'halstein-core' ), 'description' => esc_html__( 'Enter user LinkedIn profile URL', 'halstein-core' ), ) ); $page->add_field_element( array( 'field_type' => 'text', 'name' => 'qodef_user_pinterest', 'title' => esc_html__( 'Pinterest', 'halstein-core' ), 'description' => esc_html__( 'Enter user Pinterest profile URL', 'halstein-core' ), ) ); // Hook to include additional options after module options do_action( 'halstein_core_action_after_admin_user_options_map', $page ); } } add_action( 'halstein_core_action_register_role_custom_fields', 'halstein_core_add_admin_user_options' ); }
Submit
FILE
FOLDER
Name
Size
Permission
Action
role-fields.php
2262 bytes
0644
N4ST4R_ID | Naxtarrr