Addons.php
4 years ago
Admin.php
4 years ago
Ajax.php
3 years ago
Announcements.php
4 years ago
Assets.php
3 years ago
Backend_Page_Trait.php
4 years ago
Course.php
3 years ago
Course_Embed.php
3 years ago
Course_Filter.php
4 years ago
Course_List.php
3 years ago
Course_Settings_Tabs.php
4 years ago
Course_Widget.php
4 years ago
Custom_Validation.php
4 years ago
Dashboard.php
3 years ago
FormHandler.php
4 years ago
Frontend.php
3 years ago
Gutenberg.php
4 years ago
Input.php
3 years ago
Instructor.php
4 years ago
Instructors_List.php
3 years ago
Lesson.php
3 years ago
Options_V2.php
3 years ago
Post_types.php
4 years ago
Private_Course_Access.php
4 years ago
Q_and_A.php
3 years ago
Question_Answers_List.php
4 years ago
Quiz.php
3 years ago
Quiz_Attempts_List.php
3 years ago
RestAPI.php
4 years ago
Reviews.php
4 years ago
Rewrite_Rules.php
4 years ago
Shortcode.php
4 years ago
Student.php
4 years ago
Students_List.php
4 years ago
Taxonomies.php
4 years ago
Template.php
3 years ago
Theme_Compatibility.php
5 years ago
Tools.php
3 years ago
Tools_V2.php
4 years ago
Tutor.php
3 years ago
TutorEDD.php
4 years ago
Tutor_Base.php
5 years ago
Tutor_List_Table.php
4 years ago
Tutor_Setup.php
3 years ago
Upgrader.php
4 years ago
User.php
4 years ago
Utils.php
3 years ago
Video_Stream.php
4 years ago
Withdraw.php
3 years ago
Withdraw_Requests_List.php
4 years ago
WooCommerce.php
3 years ago
Custom_Validation.php
19 lines
| 1 | <?php |
| 2 | namespace TUTOR; |
| 3 | /** |
| 4 | * Custom Valaidation Trait |
| 5 | */ |
| 6 | trait Custom_Validation |
| 7 | { |
| 8 | /** |
| 9 | * Check whether order value is asc or desc |
| 10 | * |
| 11 | * @param string $order |
| 12 | * @return bool |
| 13 | */ |
| 14 | public function validate_order( $order ) |
| 15 | { |
| 16 | return in_array( strtolower( $order ), array( 'asc', 'desc' ) ); |
| 17 | } |
| 18 | } |
| 19 | ?> |