course
5 years ago
announcements-metabox.php
5 years ago
course-add-edd-product-metabox.php
5 years ago
course-add-product-metabox.php
5 years ago
course-additional-data.php
5 years ago
course-contents.php
5 years ago
course-level-metabox.php
5 years ago
course-topics.php
5 years ago
instructors-metabox.php
5 years ago
lesson-attachments-metabox.php
5 years ago
lesson-metabox.php
5 years ago
user-profile-fields.php
5 years ago
video-metabox.php
5 years ago
user-profile-fields.php
57 lines
| 1 | <h2><?php _e( 'Tutor Fields', 'tutor' ); ?></h2> |
| 2 | |
| 3 | <?php |
| 4 | /** |
| 5 | * Enqueue Media Scripts |
| 6 | */ |
| 7 | wp_enqueue_media(); |
| 8 | ?> |
| 9 | |
| 10 | <table class="form-table"> |
| 11 | |
| 12 | <tr class="user-description-wrap"> |
| 13 | <th><label for="description"><?php _e('Job Title'); ?></label></th> |
| 14 | <td> |
| 15 | <input type="text" name="_tutor_profile_job_title" id="_tutor_profile_job_title" value="<?php echo get_user_meta($user->ID, '_tutor_profile_job_title', true); ?>" class="regular-text" /> |
| 16 | </td> |
| 17 | </tr> |
| 18 | |
| 19 | <tr class="user-description-wrap"> |
| 20 | <th><label for="description"><?php _e('Profile Bio'); ?></label></th> |
| 21 | <td> |
| 22 | <?php |
| 23 | $settings = array( |
| 24 | 'teeny' => true, |
| 25 | 'media_buttons' => false, |
| 26 | 'quicktags' => false, |
| 27 | 'editor_height' => 200, |
| 28 | ); |
| 29 | wp_editor(get_user_meta($user->ID, '_tutor_profile_bio', true), '_tutor_profile_bio', $settings); |
| 30 | ?> |
| 31 | |
| 32 | <p class="description"><?php _e('Write a little bit more about you, it will show publicly.'); ?></p> |
| 33 | </td> |
| 34 | </tr> |
| 35 | |
| 36 | <tr class="user-description-wrap"> |
| 37 | <th><label for="description"><?php _e('Profile Photo'); ?></label></th> |
| 38 | <td> |
| 39 | <div class="tutor-video-poster-wrap"> |
| 40 | <p class="video-poster-img"> |
| 41 | <?php |
| 42 | $user_profile_photo = get_user_meta($user->ID, '_tutor_profile_photo', true); |
| 43 | if ($user_profile_photo){ |
| 44 | echo '<img src="'.wp_get_attachment_image_url($user_profile_photo).'" alt="" /> '; |
| 45 | } |
| 46 | ?> |
| 47 | </p> |
| 48 | <input type="hidden" name="_tutor_profile_photo_field" value="<?php echo $user_profile_photo; ?>"> |
| 49 | <button type="button" class="tutor_video_poster_upload_btn button button-primary"><?php _e('Upload', 'tutor'); ?></button> |
| 50 | </div> |
| 51 | |
| 52 | </td> |
| 53 | </tr> |
| 54 | |
| 55 | </table> |
| 56 | |
| 57 |