Version Description
22 March, 2019 =
Added: Radio input type at options panel
Added: required indication for required fields in add new instructor page from admin panel
Updated: Moved some option select to radio
Updated: Attempts allowed field slider to number field
Updated: Removed zero decimal value from the course complete progress bar
Fixed: redirect back to the quiz after quiz attempt submit
Fixed: No time limit quiz attempt finishing instantly, it should be no time limit
Fixed: video poster field show hide based on video source at the course, lesson
Download this release
Release Info
Developer | themeum |
Plugin | Tutor LMS – eLearning and online course solution |
Version | 1.0.7 |
Comparing to | |
See all releases |
Code changes from version 1.0.6 to 1.0.7
- assets/css/tutor-front.css +29 -9
- assets/icons/font/tutor.svg +0 -0
- assets/icons/font/tutor.ttf +0 -0
- assets/icons/font/tutor.woff +0 -0
- assets/js/tutor-admin.js +6 -0
- assets/js/tutor-front.js +5 -0
- assets/packages/SocialShare/SocialShare.js +0 -0
- assets/packages/SocialShare/SocialShare.min.js +0 -0
- classes/Admin.php +20 -0
- classes/Options.php +2 -3
- classes/Quiz.php +4 -2
- classes/Utils.php +1 -1
- readme.txt +13 -2
- templates/single/course/lead-info.php +1 -1
- tutor.php +3 -4
- views/metabox/video-metabox.php +1 -1
- views/options/field-types/number.php +7 -0
- views/options/field-types/radio.php +18 -0
- views/pages/add_new_instructor.php +8 -0
assets/css/tutor-front.css
CHANGED
@@ -279,6 +279,10 @@ Most Important CSS
|
|
279 |
font-weight: 500;
|
280 |
}
|
281 |
|
|
|
|
|
|
|
|
|
282 |
.tutor-single-course-meta ul li{
|
283 |
font-weight: 500;
|
284 |
color: #4B5981;
|
@@ -329,7 +333,8 @@ Most Important CSS
|
|
329 |
}
|
330 |
|
331 |
.tutor-single-course-meta.tutor-lead-meta ul li a:not(:last-child):after{
|
332 |
-
content: ',
|
|
|
333 |
}
|
334 |
/*benifit*/
|
335 |
.tutor-course-benefits-content ul{
|
@@ -610,7 +615,7 @@ div[class*="tutor-course-col"] {
|
|
610 |
transition: 100ms;
|
611 |
border-bottom-left-radius: 4px;
|
612 |
border-bottom-right-radius: 4px;
|
613 |
-
background:
|
614 |
}
|
615 |
.tutor-loop-course-footer .tutor-loop-cart-btn-wrap a{
|
616 |
color: #fff;
|
@@ -623,7 +628,7 @@ div[class*="tutor-course-col"] {
|
|
623 |
display: block;
|
624 |
width: 100%;
|
625 |
line-height: 54px;
|
626 |
-
background:
|
627 |
}
|
628 |
.tutor-loop-course-footer .tutor-loop-cart-btn-wrap a.added{
|
629 |
display: none;
|
@@ -830,7 +835,7 @@ a.tutor-btn,
|
|
830 |
border-radius: 4px;
|
831 |
text-transform: uppercase;
|
832 |
line-height: 1.4;
|
833 |
-
font-size:
|
834 |
font-weight: 500;
|
835 |
}
|
836 |
a.tutor-button:hover,
|
@@ -1196,7 +1201,7 @@ Instructor
|
|
1196 |
.tutor-topics-in-single-lesson{
|
1197 |
margin-bottom: 25px;
|
1198 |
background-color: #ffffff;
|
1199 |
-
padding: 10px 0;
|
1200 |
}
|
1201 |
.tutor-topics-in-single-lesson .tutor-single-lesson-items a span{
|
1202 |
font-size: 14px;
|
@@ -1288,16 +1293,28 @@ Instructor
|
|
1288 |
display: -webkit-box;
|
1289 |
display: -ms-flexbox;
|
1290 |
display: flex;
|
1291 |
-
|
|
|
1292 |
}
|
1293 |
.tutor-single-page-top-bar a{
|
1294 |
color: #ffffff;
|
1295 |
}
|
1296 |
-
|
1297 |
-
|
|
|
1298 |
}
|
|
|
1299 |
.tutor-single-page-top-bar .tutor-topbar-content-title-wrap{
|
1300 |
text-align: center;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1301 |
}
|
1302 |
.tutor-single-page-top-bar .tutor-topbar-back-to-curse-wrap{
|
1303 |
text-align: right;
|
@@ -1624,6 +1641,9 @@ Instructor
|
|
1624 |
padding: 15px;
|
1625 |
}
|
1626 |
|
|
|
|
|
|
|
1627 |
|
1628 |
|
1629 |
/*******************/
|
@@ -2721,7 +2741,7 @@ Course question and answer
|
|
2721 |
line-height: 50px;
|
2722 |
color: #ffffff;
|
2723 |
font-size: 14px;
|
2724 |
-
text-shadow: 0 0
|
2725 |
}
|
2726 |
.course-avg-rating-wrap .course-avg-rating {
|
2727 |
font-size: 76px;
|
279 |
font-weight: 500;
|
280 |
}
|
281 |
|
282 |
+
.tutor-single-course-meta.tutor-meta-top ul li,
|
283 |
+
.tutor-single-course-meta.tutor-meta-top ul li a{
|
284 |
+
font-weight: 700;
|
285 |
+
}
|
286 |
.tutor-single-course-meta ul li{
|
287 |
font-weight: 500;
|
288 |
color: #4B5981;
|
333 |
}
|
334 |
|
335 |
.tutor-single-course-meta.tutor-lead-meta ul li a:not(:last-child):after{
|
336 |
+
content: ',';
|
337 |
+
margin-right: 4px;
|
338 |
}
|
339 |
/*benifit*/
|
340 |
.tutor-course-benefits-content ul{
|
615 |
transition: 100ms;
|
616 |
border-bottom-left-radius: 4px;
|
617 |
border-bottom-right-radius: 4px;
|
618 |
+
background: #1B52D8;
|
619 |
}
|
620 |
.tutor-loop-course-footer .tutor-loop-cart-btn-wrap a{
|
621 |
color: #fff;
|
628 |
display: block;
|
629 |
width: 100%;
|
630 |
line-height: 54px;
|
631 |
+
background: #1B52D8;
|
632 |
}
|
633 |
.tutor-loop-course-footer .tutor-loop-cart-btn-wrap a.added{
|
634 |
display: none;
|
835 |
border-radius: 4px;
|
836 |
text-transform: uppercase;
|
837 |
line-height: 1.4;
|
838 |
+
font-size: 12px;
|
839 |
font-weight: 500;
|
840 |
}
|
841 |
a.tutor-button:hover,
|
1201 |
.tutor-topics-in-single-lesson{
|
1202 |
margin-bottom: 25px;
|
1203 |
background-color: #ffffff;
|
1204 |
+
padding: 10px 0 0;
|
1205 |
}
|
1206 |
.tutor-topics-in-single-lesson .tutor-single-lesson-items a span{
|
1207 |
font-size: 14px;
|
1293 |
display: -webkit-box;
|
1294 |
display: -ms-flexbox;
|
1295 |
display: flex;
|
1296 |
+
align-items: center;
|
1297 |
+
justify-content: space-between;
|
1298 |
}
|
1299 |
.tutor-single-page-top-bar a{
|
1300 |
color: #ffffff;
|
1301 |
}
|
1302 |
+
|
1303 |
+
.tutor-single-page-top-bar a:hover{
|
1304 |
+
color: #ffffff;
|
1305 |
}
|
1306 |
+
|
1307 |
.tutor-single-page-top-bar .tutor-topbar-content-title-wrap{
|
1308 |
text-align: center;
|
1309 |
+
max-width: 600px;
|
1310 |
+
white-space: nowrap;
|
1311 |
+
overflow: hidden;
|
1312 |
+
text-overflow: ellipsis;
|
1313 |
+
}
|
1314 |
+
.tutor-single-page-top-bar .tutor-topbar-content-title-wrap i{
|
1315 |
+
vertical-align: middle;
|
1316 |
+
line-height: 1;
|
1317 |
+
margin-right: 3px;
|
1318 |
}
|
1319 |
.tutor-single-page-top-bar .tutor-topbar-back-to-curse-wrap{
|
1320 |
text-align: right;
|
1641 |
padding: 15px;
|
1642 |
}
|
1643 |
|
1644 |
+
.tutor-write-review-form{
|
1645 |
+
margin-top: 30px;
|
1646 |
+
}
|
1647 |
|
1648 |
|
1649 |
/*******************/
|
2741 |
line-height: 50px;
|
2742 |
color: #ffffff;
|
2743 |
font-size: 14px;
|
2744 |
+
text-shadow: 0 1px 2px rgba(0,0,0, .4);
|
2745 |
}
|
2746 |
.course-avg-rating-wrap .course-avg-rating {
|
2747 |
font-size: 76px;
|
assets/icons/font/tutor.svg
CHANGED
File without changes
|
assets/icons/font/tutor.ttf
CHANGED
File without changes
|
assets/icons/font/tutor.woff
CHANGED
File without changes
|
assets/js/tutor-admin.js
CHANGED
@@ -368,6 +368,12 @@ jQuery(document).ready(function($){
|
|
368 |
var selector = $(this).val();
|
369 |
$('[class^="video_source_wrap"]').hide();
|
370 |
$('.video_source_wrap_'+selector).show();
|
|
|
|
|
|
|
|
|
|
|
|
|
371 |
});
|
372 |
|
373 |
$(document).on( 'click', '.video_source_wrap_html5 .video_upload_btn', function( event ){
|
368 |
var selector = $(this).val();
|
369 |
$('[class^="video_source_wrap"]').hide();
|
370 |
$('.video_source_wrap_'+selector).show();
|
371 |
+
|
372 |
+
if (selector === 'html5'){
|
373 |
+
$('.tutor-video-poster-field').show();
|
374 |
+
} else{
|
375 |
+
$('.tutor-video-poster-field').hide();
|
376 |
+
}
|
377 |
});
|
378 |
|
379 |
$(document).on( 'click', '.video_source_wrap_html5 .video_upload_btn', function( event ){
|
assets/js/tutor-front.js
CHANGED
@@ -234,6 +234,11 @@ jQuery(document).ready(function($){
|
|
234 |
attempt_settings = JSON.parse($tutor_quiz_time_update.attr('data-attempt-settings'));
|
235 |
var attempt_meta = JSON.parse($tutor_quiz_time_update.attr('data-attempt-meta'));
|
236 |
|
|
|
|
|
|
|
|
|
|
|
237 |
var countDownDate = new Date(attempt_settings.attempt_started_at).getTime() + (attempt_meta.time_limit.time_limit_seconds * 1000);
|
238 |
var time_now = new Date(attempt_meta.date_time_now).getTime();
|
239 |
|
234 |
attempt_settings = JSON.parse($tutor_quiz_time_update.attr('data-attempt-settings'));
|
235 |
var attempt_meta = JSON.parse($tutor_quiz_time_update.attr('data-attempt-meta'));
|
236 |
|
237 |
+
if (attempt_meta.time_limit.time_limit_seconds === 0) {
|
238 |
+
//No time Zero limit for
|
239 |
+
return;
|
240 |
+
}
|
241 |
+
|
242 |
var countDownDate = new Date(attempt_settings.attempt_started_at).getTime() + (attempt_meta.time_limit.time_limit_seconds * 1000);
|
243 |
var time_now = new Date(attempt_meta.date_time_now).getTime();
|
244 |
|
assets/packages/SocialShare/SocialShare.js
CHANGED
File without changes
|
assets/packages/SocialShare/SocialShare.min.js
CHANGED
File without changes
|
classes/Admin.php
CHANGED
@@ -23,6 +23,9 @@ class Admin{
|
|
23 |
|
24 |
add_action('admin_action_uninstall_tutor_and_erase', array($this, 'erase_tutor_data'));
|
25 |
add_filter('plugin_action_links_' . plugin_basename(TUTOR_FILE), array( $this, 'plugin_action_links' ) );
|
|
|
|
|
|
|
26 |
}
|
27 |
|
28 |
public function register_menu(){
|
@@ -395,6 +398,23 @@ class Admin{
|
|
395 |
return $actions;
|
396 |
}
|
397 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
398 |
|
399 |
|
400 |
}
|
23 |
|
24 |
add_action('admin_action_uninstall_tutor_and_erase', array($this, 'erase_tutor_data'));
|
25 |
add_filter('plugin_action_links_' . plugin_basename(TUTOR_FILE), array( $this, 'plugin_action_links' ) );
|
26 |
+
|
27 |
+
//Plugin Row Meta
|
28 |
+
add_filter('plugin_row_meta', array($this, 'plugin_row_meta'), 10, 2);
|
29 |
}
|
30 |
|
31 |
public function register_menu(){
|
398 |
return $actions;
|
399 |
}
|
400 |
|
401 |
+
public function plugin_row_meta($plugin_meta, $plugin_file){
|
402 |
+
|
403 |
+
|
404 |
+
if ($plugin_file === tutor()->basename) {
|
405 |
+
$plugin_meta[] = sprintf( '<a href="%s">%s</a>',
|
406 |
+
esc_url( 'https://www.themeum.com/docs/tutor-introduction/?utm_source=tutor&utm_medium=plugins_installation_list&utm_campaign=plugin_docs_link' ),
|
407 |
+
__( '<strong style="color: #03bd24">Documentation</strong>', 'tutor' )
|
408 |
+
);
|
409 |
+
$plugin_meta[] = sprintf( '<a href="%s">%s</a>',
|
410 |
+
esc_url( 'https://www.themeum.com/support-forums/?utm_source=tutor&utm_medium=plugins_installation_list&utm_campaign=plugin_support_link' ),
|
411 |
+
__( '<strong style="color: #03bd24">Get Support</strong>', 'tutor' )
|
412 |
+
);
|
413 |
+
}
|
414 |
+
|
415 |
+
return $plugin_meta;
|
416 |
+
}
|
417 |
+
|
418 |
|
419 |
|
420 |
}
|
classes/Options.php
CHANGED
@@ -213,7 +213,7 @@ class Options {
|
|
213 |
),
|
214 |
|
215 |
'quiz_when_time_expires' => array(
|
216 |
-
'type' => '
|
217 |
'label' => __('When time expires', 'tutor'),
|
218 |
'default' => 'minutes',
|
219 |
'select_options' => false,
|
@@ -226,10 +226,9 @@ class Options {
|
|
226 |
),
|
227 |
|
228 |
'quiz_attempts_allowed' => array(
|
229 |
-
'type' => '
|
230 |
'label' => __('Attempts allowed', 'tutor'),
|
231 |
'default' => '10',
|
232 |
-
'options' => array('min'=> 0, 'max' => 20),
|
233 |
'desc' => __('Restriction on the number of attempts students are allowed to take for a quiz. 0 for no limit', 'tutor'),
|
234 |
),
|
235 |
|
213 |
),
|
214 |
|
215 |
'quiz_when_time_expires' => array(
|
216 |
+
'type' => 'radio',
|
217 |
'label' => __('When time expires', 'tutor'),
|
218 |
'default' => 'minutes',
|
219 |
'select_options' => false,
|
226 |
),
|
227 |
|
228 |
'quiz_attempts_allowed' => array(
|
229 |
+
'type' => 'number',
|
230 |
'label' => __('Attempts allowed', 'tutor'),
|
231 |
'default' => '10',
|
|
|
232 |
'desc' => __('Restriction on the number of attempts students are allowed to take for a quiz. 0 for no limit', 'tutor'),
|
233 |
),
|
234 |
|
classes/Quiz.php
CHANGED
@@ -316,6 +316,9 @@ class Quiz {
|
|
316 |
//Checking nonce
|
317 |
tutor_utils()->checking_nonce();
|
318 |
|
|
|
|
|
|
|
319 |
$attempt_answers = isset($_POST['attempt']) ? $_POST['attempt'] : false;
|
320 |
if ( ! is_user_logged_in()){
|
321 |
die('Please sign in to do this operation');
|
@@ -326,7 +329,6 @@ class Quiz {
|
|
326 |
|
327 |
if ($attempt_answers && is_array($attempt_answers) && count($attempt_answers)){
|
328 |
foreach ($attempt_answers as $attempt_id => $attempt_answers){
|
329 |
-
$attempt = tutor_utils()->get_attempt($attempt_id);
|
330 |
|
331 |
/**
|
332 |
* Get total marks of all question comes
|
@@ -436,7 +438,7 @@ class Quiz {
|
|
436 |
}
|
437 |
}
|
438 |
|
439 |
-
wp_redirect(
|
440 |
die();
|
441 |
}
|
442 |
|
316 |
//Checking nonce
|
317 |
tutor_utils()->checking_nonce();
|
318 |
|
319 |
+
$attempt_id = (int) sanitize_text_field(tutor_utils()->avalue_dot('attempt_id', $_POST));
|
320 |
+
$attempt = tutor_utils()->get_attempt($attempt_id);
|
321 |
+
|
322 |
$attempt_answers = isset($_POST['attempt']) ? $_POST['attempt'] : false;
|
323 |
if ( ! is_user_logged_in()){
|
324 |
die('Please sign in to do this operation');
|
329 |
|
330 |
if ($attempt_answers && is_array($attempt_answers) && count($attempt_answers)){
|
331 |
foreach ($attempt_answers as $attempt_id => $attempt_answers){
|
|
|
332 |
|
333 |
/**
|
334 |
* Get total marks of all question comes
|
438 |
}
|
439 |
}
|
440 |
|
441 |
+
wp_redirect(get_the_permalink($attempt->quiz_id));
|
442 |
die();
|
443 |
}
|
444 |
|
classes/Utils.php
CHANGED
@@ -606,7 +606,7 @@ class Utils {
|
|
606 |
$completed_lesson = $this->get_completed_lesson_count_by_course($course_id, $user_id);
|
607 |
|
608 |
if ($total_lesson > 0 && $completed_lesson > 0){
|
609 |
-
return number_format(($completed_lesson * 100) / $total_lesson
|
610 |
}
|
611 |
|
612 |
return 0;
|
606 |
$completed_lesson = $this->get_completed_lesson_count_by_course($course_id, $user_id);
|
607 |
|
608 |
if ($total_lesson > 0 && $completed_lesson > 0){
|
609 |
+
return number_format(($completed_lesson * 100) / $total_lesson);
|
610 |
}
|
611 |
|
612 |
return 0;
|
readme.txt
CHANGED
@@ -5,7 +5,7 @@ Tags: lms, education, wp-lms, education management system
|
|
5 |
Requires at least: 4.5
|
6 |
Tested up to: 5.1
|
7 |
Requires PHP: 5.4.0
|
8 |
-
Stable tag: 1.0.
|
9 |
License: GPLv3
|
10 |
License URI: https://www.gnu.org/licenses/gpl-3.0.html
|
11 |
|
@@ -183,7 +183,18 @@ This is an alpha version of Tutor, as bugs and issues expected, if you found any
|
|
183 |
|
184 |
== Changelog ==
|
185 |
|
186 |
-
= 1.0.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
187 |
|
188 |
* Added: Drop tutor LMS related database table while uninstalling
|
189 |
* Updated: option tab design
|
5 |
Requires at least: 4.5
|
6 |
Tested up to: 5.1
|
7 |
Requires PHP: 5.4.0
|
8 |
+
Stable tag: 1.0.7
|
9 |
License: GPLv3
|
10 |
License URI: https://www.gnu.org/licenses/gpl-3.0.html
|
11 |
|
183 |
|
184 |
== Changelog ==
|
185 |
|
186 |
+
= 1.0.7 - 22 March, 2019 =
|
187 |
+
|
188 |
+
* Added: Radio input type at options panel
|
189 |
+
* Added: required indication for required fields in add new instructor page from admin panel
|
190 |
+
* Updated: Moved some option select to radio
|
191 |
+
* Updated: Attempts allowed field slider to number field
|
192 |
+
* Updated: Removed zero decimal value from the course complete progress bar
|
193 |
+
* Fixed: redirect back to the quiz after quiz attempt submit
|
194 |
+
* Fixed: No time limit quiz attempt finishing instantly, it should be no time limit
|
195 |
+
* Fixed: video poster field show hide based on video source at the course, lesson
|
196 |
+
|
197 |
+
= 1.0.6 - 20 March, 2019 =
|
198 |
|
199 |
* Added: Drop tutor LMS related database table while uninstalling
|
200 |
* Updated: option tab design
|
templates/single/course/lead-info.php
CHANGED
@@ -73,7 +73,7 @@ $profile_url = tutor_utils()->profile_url($authordata->ID);
|
|
73 |
foreach ($course_categories as $course_category){
|
74 |
$category_name = $course_category->name;
|
75 |
$category_link = get_term_link($course_category->term_id);
|
76 |
-
echo "<a href='$category_link'>$category_name</a>
|
77 |
}
|
78 |
?>
|
79 |
</li>
|
73 |
foreach ($course_categories as $course_category){
|
74 |
$category_name = $course_category->name;
|
75 |
$category_link = get_term_link($course_category->term_id);
|
76 |
+
echo "<a href='$category_link'>$category_name</a>";
|
77 |
}
|
78 |
?>
|
79 |
</li>
|
tutor.php
CHANGED
@@ -2,10 +2,9 @@
|
|
2 |
/*
|
3 |
Plugin Name: Tutor LMS
|
4 |
Plugin URI: http://https://themeum.com/tutor
|
5 |
-
Description: Tutor is a complete solution for creating a Learning Management System in WordPress way. It can help you to create
|
6 |
-
courses, lessons and quizzes.
|
7 |
Author: Themeum
|
8 |
-
Version: 1.0.
|
9 |
Author URI: http://themeum.com
|
10 |
Requires at least: 4.5
|
11 |
Tested up to: 5.1
|
@@ -18,7 +17,7 @@ if ( ! defined( 'ABSPATH' ) )
|
|
18 |
/**
|
19 |
* Defined the tutor main file
|
20 |
*/
|
21 |
-
define('TUTOR_VERSION', '1.0.
|
22 |
define('TUTOR_FILE', __FILE__);
|
23 |
|
24 |
|
2 |
/*
|
3 |
Plugin Name: Tutor LMS
|
4 |
Plugin URI: http://https://themeum.com/tutor
|
5 |
+
Description: Tutor is a complete solution for creating a Learning Management System in WordPress way. It can help you to create small to large scale online education site very conveniently. Power features like report, certificate, course preview, private file sharing make Tutor a robust plugin for any educational institutes.
|
|
|
6 |
Author: Themeum
|
7 |
+
Version: 1.0.7
|
8 |
Author URI: http://themeum.com
|
9 |
Requires at least: 4.5
|
10 |
Tested up to: 5.1
|
17 |
/**
|
18 |
* Defined the tutor main file
|
19 |
*/
|
20 |
+
define('TUTOR_VERSION', '1.0.7');
|
21 |
define('TUTOR_FILE', __FILE__);
|
22 |
|
23 |
|
views/metabox/video-metabox.php
CHANGED
@@ -85,7 +85,7 @@ $poster = tutor_utils()->avalue_dot('poster', $video);
|
|
85 |
</div>
|
86 |
</div>
|
87 |
|
88 |
-
<div class="tutor-option-field-row">
|
89 |
<div class="tutor-option-field-label">
|
90 |
<label for=""><?php _e('Video Poster', 'tutor'); ?></label>
|
91 |
</div>
|
85 |
</div>
|
86 |
</div>
|
87 |
|
88 |
+
<div class="tutor-option-field-row tutor-video-poster-field" style="display: <?php echo $videoSource === 'html5' ? 'block': 'none'; ?>;">
|
89 |
<div class="tutor-option-field-label">
|
90 |
<label for=""><?php _e('Video Poster', 'tutor'); ?></label>
|
91 |
</div>
|
views/options/field-types/number.php
ADDED
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
$value = $this->get($field['field_key']);
|
3 |
+
if ( ! $value && isset($field['default'])){
|
4 |
+
$value = $field['default'];
|
5 |
+
}
|
6 |
+
?>
|
7 |
+
<input type="number" name="tutor_option[<?php echo $field['field_key']; ?>]" value="<?php echo $value; ?>" >
|
views/options/field-types/radio.php
ADDED
@@ -0,0 +1,18 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
|
2 |
+
|
3 |
+
<?php
|
4 |
+
if ( ! isset($field['select_options']) || $field['select_options'] !== false){
|
5 |
+
echo '<option value="-1">'.__('Select Option', 'tutor').'</option>';
|
6 |
+
}
|
7 |
+
if ( ! empty($field['options'])){
|
8 |
+
foreach ($field['options'] as $optionKey => $option){
|
9 |
+
?>
|
10 |
+
<p><label>
|
11 |
+
<input type="radio" name="tutor_option[<?php echo $field['field_key']; ?>]" value="<?php echo $optionKey ?>" <?php checked($this->get($field['field_key']), $optionKey) ?> />
|
12 |
+
<?php echo $option ?>
|
13 |
+
</label></p>
|
14 |
+
|
15 |
+
<?php
|
16 |
+
}
|
17 |
+
}
|
18 |
+
?>
|
views/pages/add_new_instructor.php
CHANGED
@@ -25,6 +25,8 @@
|
|
25 |
<div class="tutor-option-field-label">
|
26 |
<label for="">
|
27 |
<?php _e('First Name', 'tutor'); ?>
|
|
|
|
|
28 |
</label>
|
29 |
</div>
|
30 |
<div class="tutor-option-field">
|
@@ -37,6 +39,7 @@
|
|
37 |
<div class="tutor-option-field-label">
|
38 |
<label>
|
39 |
<?php _e('Last Name', 'tutor'); ?>
|
|
|
40 |
</label>
|
41 |
</div>
|
42 |
|
@@ -49,6 +52,7 @@
|
|
49 |
<div class="tutor-option-field-label">
|
50 |
<label>
|
51 |
<?php _e('User Name', 'tutor'); ?>
|
|
|
52 |
</label>
|
53 |
</div>
|
54 |
|
@@ -61,6 +65,7 @@
|
|
61 |
<div class="tutor-option-field-label">
|
62 |
<label>
|
63 |
<?php _e('E-Mail', 'tutor'); ?>
|
|
|
64 |
</label>
|
65 |
</div>
|
66 |
|
@@ -73,6 +78,7 @@
|
|
73 |
<div class="tutor-option-field-label">
|
74 |
<label>
|
75 |
<?php _e('Phone Number', 'tutor'); ?>
|
|
|
76 |
</label>
|
77 |
</div>
|
78 |
|
@@ -85,6 +91,7 @@
|
|
85 |
<div class="tutor-option-field-label">
|
86 |
<label>
|
87 |
<?php _e('Password', 'tutor'); ?>
|
|
|
88 |
</label>
|
89 |
</div>
|
90 |
|
@@ -97,6 +104,7 @@
|
|
97 |
<div class="tutor-option-field-label">
|
98 |
<label>
|
99 |
<?php _e('Password confirmation', 'tutor'); ?>
|
|
|
100 |
</label>
|
101 |
</div>
|
102 |
|
25 |
<div class="tutor-option-field-label">
|
26 |
<label for="">
|
27 |
<?php _e('First Name', 'tutor'); ?>
|
28 |
+
|
29 |
+
<span class="tutor-required-fields">*</span>
|
30 |
</label>
|
31 |
</div>
|
32 |
<div class="tutor-option-field">
|
39 |
<div class="tutor-option-field-label">
|
40 |
<label>
|
41 |
<?php _e('Last Name', 'tutor'); ?>
|
42 |
+
<span class="tutor-required-fields">*</span>
|
43 |
</label>
|
44 |
</div>
|
45 |
|
52 |
<div class="tutor-option-field-label">
|
53 |
<label>
|
54 |
<?php _e('User Name', 'tutor'); ?>
|
55 |
+
<span class="tutor-required-fields">*</span>
|
56 |
</label>
|
57 |
</div>
|
58 |
|
65 |
<div class="tutor-option-field-label">
|
66 |
<label>
|
67 |
<?php _e('E-Mail', 'tutor'); ?>
|
68 |
+
<span class="tutor-required-fields">*</span>
|
69 |
</label>
|
70 |
</div>
|
71 |
|
78 |
<div class="tutor-option-field-label">
|
79 |
<label>
|
80 |
<?php _e('Phone Number', 'tutor'); ?>
|
81 |
+
<span class="tutor-required-fields">*</span>
|
82 |
</label>
|
83 |
</div>
|
84 |
|
91 |
<div class="tutor-option-field-label">
|
92 |
<label>
|
93 |
<?php _e('Password', 'tutor'); ?>
|
94 |
+
<span class="tutor-required-fields">*</span>
|
95 |
</label>
|
96 |
</div>
|
97 |
|
104 |
<div class="tutor-option-field-label">
|
105 |
<label>
|
106 |
<?php _e('Password confirmation', 'tutor'); ?>
|
107 |
+
<span class="tutor-required-fields">*</span>
|
108 |
</label>
|
109 |
</div>
|
110 |
|