| 1 |
<?php |
| 2 |
$currencies = learn_press_currencies(); |
| 3 |
|
| 4 |
foreach ( $currencies as $code => $name ) { |
| 5 |
$currency_symbol = learn_press_get_currency_symbol( $code ); |
| 6 |
$currencies[ $code ] = sprintf( '%s (%s)', $name, $currency_symbol ); |
| 7 |
} |
| 8 |
|
| 9 |
return apply_filters( |
| 10 |
'learn-press/course-settings-fields/single', |
| 11 |
[ |
| 12 |
[ |
| 13 |
'title' => esc_html__( 'Permalinks', 'learnpress' ), |
| 14 |
'type' => 'title', |
| 15 |
], |
| 16 |
[ |
| 17 |
'title' => esc_html__( 'Course', 'learnpress' ), |
| 18 |
'type' => 'course-permalink', |
| 19 |
'default' => '', |
| 20 |
'id' => 'course_base', |
| 21 |
], |
| 22 |
[ |
| 23 |
'title' => esc_html__( 'Lesson', 'learnpress' ), |
| 24 |
'type' => 'text', |
| 25 |
'id' => 'lesson_slug', |
| 26 |
'desc' => sprintf( 'e.g. %s/course/sample-course/<code>lessons</code>/sample-lesson/', home_url() ), |
| 27 |
'default' => 'lessons', |
| 28 |
'placeholder' => 'lesson', |
| 29 |
], |
| 30 |
[ |
| 31 |
'title' => esc_html__( 'Quiz', 'learnpress' ), |
| 32 |
'type' => 'text', |
| 33 |
'id' => 'quiz_slug', |
| 34 |
'desc' => sprintf( 'e.g. %s/course/sample-course/<code>quizzes</code>/sample-quiz/', home_url() ), |
| 35 |
'default' => 'quizzes', |
| 36 |
'placeholder' => 'quizzes', |
| 37 |
], |
| 38 |
[ |
| 39 |
'title' => esc_html__( 'Category base', 'learnpress' ), |
| 40 |
'id' => 'course_category_base', |
| 41 |
'default' => 'course-category', |
| 42 |
'type' => 'text', |
| 43 |
'placeholder' => 'course-category', |
| 44 |
'desc' => sprintf( 'e.g. %s/course/%s/sample-category/', home_url(), '<code>course-category</code>' ), |
| 45 |
], |
| 46 |
[ |
| 47 |
'title' => esc_html__( 'Tag base', 'learnpress' ), |
| 48 |
'id' => 'course_tag_base', |
| 49 |
'default' => 'course-tag', |
| 50 |
'type' => 'text', |
| 51 |
'placeholder' => 'course-tag', |
| 52 |
'desc' => sprintf( 'e.g. %s/course/%s/sample-tag/', home_url(), '<code>course-tag</code>' ), |
| 53 |
], |
| 54 |
[ |
| 55 |
'type' => 'sectionend', |
| 56 |
], |
| 57 |
] |
| 58 |
); |
| 59 |
|