Skip to content

Instantly share code, notes, and snippets.

Avatar

Rocco Aliberti eri-trabiccolo

  • Pinerolo (TO), Italy
View GitHub Profile
View llms_remove_sidebar_on_catalogs.php
<?php // do not copy this line
remove_action( 'lifterlms_sidebar', 'lifterlms_get_sidebar', 10 );
@eri-trabiccolo
eri-trabiccolo / elementor-pro-llms-certificates-no-header.css
Created Jul 20, 2020
No header built with Elementor Pro in LLMS certificates
View elementor-pro-llms-certificates-no-header.css
.single-llms_my_certificate .elementor-location-header,
.single-llms_certificate .elementor-location-header {
display: none;
}
View wp-debug-all.php
<?php // don't copy this line
define( 'WP_DEBUG', true );
define( 'WP_DEBUG_LOG', true );
define( 'WP_DEBUG_DISPLAY', true );
@eri-trabiccolo
eri-trabiccolo / lifterlms-custom-profile-fields-add.php
Last active Mar 30, 2020 — forked from actual-saurabh/lifterlms-custom-profile-fields-add.php
Custom Fields added to LifterLMS Registration/Checkout
View lifterlms-custom-profile-fields-add.php
<?php // don't copy this line to your functions.php file
/**
*
* Create Company Industry as a custom field upon registration or checkout
*
* @param $fields - fields already being registered
* @param $screen - either checkout or registration screen
* @return $fields - array with added field
*/
function add_company_industry_lifterlms ( $fields , $screen ) {
@eri-trabiccolo
eri-trabiccolo / llms_quiz_question_show_ui.php
Last active Jun 20, 2019
Show LLMS quiz and question post type UI
View llms_quiz_question_show_ui.php
<?php //<- don' copy this whole line!
// Copy from under this line and paste into your child theme's functions.php or in the LifterLMS Customization plugin
add_filter( 'register_post_type_args', 'my_llms_show_quiz_questions_ui', 10, 2 );
function my_llms_show_quiz_questions_ui( $args, $post_type ) {
if ( in_array( $post_type, array( 'llms_quiz', 'llms_question' ) ) ) {
$args['show_ui'] = true;
}
return $args;
}
@eri-trabiccolo
eri-trabiccolo / remove-unwanted-slashes-from-access-plan-description.php
Last active May 27, 2019
Remove unwanted slashes added to the access plan description
View remove-unwanted-slashes-from-access-plan-description.php
<?php // Do not copy this line
// Copy from under this line and paste into your child theme's functions.php
$unslash_iterarions = 2; //at least 2 times
for ( $i = 1; $i <= $unslash_iterarions; $i++ ) {
add_filter( 'llms_access_before_save_plan', 'wp_unslash', $i );
}
@eri-trabiccolo
eri-trabiccolo / llms-focus-mode.css
Last active Apr 18, 2019 — forked from actual-saurabh/llms-focus-mode.css
LifterLMS Distraction Free Fullscreen mode
View llms-focus-mode.css
body.llms-is-focused .content-area {
background: #fff none;
padding:0;
overflow-y: auto;
position:fixed;
width:100%;
height:100%;
top:0;
left:0;
bottom:0;
@eri-trabiccolo
eri-trabiccolo / disable_dropdown_placement.php
Created Oct 7, 2016
Disable dropdown placement js feature in the Customizr(-PRO) theme
View disable_dropdown_placement.php
add_filter( 'tc_disabled_front_js_parts', 'pc_disable_dropdown_placement_script' );
function pc_disable_dropdown_placement_script( $_parts ){
return array_merge( $_parts, array('Czr_DropdownPlace' => array()) );
}
View use_woocommerce_breadcrumbs.php
add_action( 'wp', 'tc_woocommerce_breadcrumb', 100 );
function tc_woocommerce_breadcrumb() {
//do nothing if we're not in the wc context
if ( ! ( function_exists( 'is_woocommerce' ) && is_woocommerce() ) )
return;
//turn off the theme's breadcrumb
add_filter( 'tc_opt_tc_breadcrumb', '__return_false' );
//display woocommerce breadcrumb before the main container
@eri-trabiccolo
eri-trabiccolo / archive-listing.php
Created Feb 17, 2016
Customizr - WP_Listings: Archive template
View archive-listing.php
<?php
/**
* The template for displaying Listing Archive pages
*
* @link http://codex.wordpress.org/Template_Hierarchy
*
* @package WP Listings
* @since 0.1.0
*/
You can’t perform that action at this time.