This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php // do not add this line to your file when copying! | |
// add this to your wp-config.php file | |
// navigate to the whitescreen page and add ?debug=debug to the url | |
// eg: http://mywebsite.com/problempage?debug=debug | |
// or on a page with query string variables already http://mywebsite.com/problempage?variable=123&debug=debug | |
if ( isset( $_GET['debug'] ) && 'debug' == $_GET['debug'] ) { | |
define( 'WP_DEBUG', true ); | |
define( 'WP_DEBUG_DISPLAY', true ); | |
define( 'SCRIPT_DEBUG', true ); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Plugin Name: LifterLMS | |
* Plugin URI: https://lifterlms.com/ | |
* Description: LifterLMS, the #1 WordPress LMS solution, makes it easy to create, sell, and protect engaging online courses. | |
* Version: 2.0.4 | |
* Author: Mark Nelson, Thomas Patrick Levy, codeBOX, LLC | |
* Author URI: http://gocodebox.com | |
* Text Domain: lifterlms | |
* Domain Path: /languages |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
find . -name "*.php" -print0 | xargs -0 -n1 -P8 php -l |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// add an action to the hook | |
add_action( 'lifterlms_register_form', 'my_custom_lifterlms_registration_fields' ); | |
// create the function that add_action will call | |
// this function should echo or output html | |
// the HTML below follows the format of the other fields LifterLMS outputs by default | |
function my_custom_lifterlms_registration_fields() { | |
?> | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// add an action to the hook | |
add_action( 'lifterlms_user_registered', 'save_my_custom_lifterlms_registration_fields', 10, 1 ); | |
// create the function that add_action will call | |
// $user_id is going to be the WP User ID of the newly created user | |
function save_my_custom_lifterlms_registration_fields( $user_id ) { | |
// look at $_POST to find the fields you've created in the previous function |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php // don't include this line when copying | |
/** | |
* Add custom validation to the LifterLMS Registration Form | |
* @param obj $errors instance of WP_Error | |
* @return obj | |
*/ | |
function my_lifterlms_registration_validation( $errors ) { | |
// if the phone number field is not submitted or is empty |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Page functions | |
* | |
* Functions used for managing page / post access | |
* | |
* @author codeBOX | |
* @project lifterLMS | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Shortcode base class | |
* | |
* Shortcode logic | |
* | |
* @version 1.0 | |
* @author codeBOX | |
* @project lifterLMS |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.llms-progress-circle-count { top: 38%; } | |
.llms-quiz-result-details { margin-top: 25px; } | |
.llms-quiz-result-details ul { list-style-type: none !important; } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php // don't copy this line into your functions.php file | |
// make Great Britain the default country in the country list on LifterLMS Country Selects | |
add_filter( 'lifterlms_countries', function( $countries ) { | |
$countires = array_merge( array( 'GB' => $counties['GB'] ) , $countries ); | |
return $countires; | |
} ); |