Skip to content

Instantly share code, notes, and snippets.

View madhvendras84's full-sized avatar

Madhvendra Singh madhvendras84

View GitHub Profile
@madhvendras84
madhvendras84 / single.php
Created September 22, 2023 12:48
Backup before changes applied - prorevuz.biz - Edubin: single.php (template-parts/post/single.php)
<?php
/**
* Template part for displaying posts
* @package Edubin
* Version: 1.0.0
*/
$post_id = edubin_get_id();
$prefix = '_edubin_';
$defaults = edubin_generate_defaults();
$page_header_enable = get_post_meta($post_id, $prefix . 'page_header_enable', true);
@madhvendras84
madhvendras84 / Stop WordPress updates
Created September 15, 2023 12:25
Stop WordPress / plugin / theme updates
/*
********************************************************************************************************************
****************************** Stop wordpress / plugin / theme updates *********************************************
********************************************************************************************************************
*/
function shakti_remove_wp_core_updates()
{
global $wp_version;
return (object)array(
function custom_my_account_menu_items( $items ) {
unset($items['downloads']);
return $items;
}
add_filter( 'woocommerce_account_menu_items', 'custom_my_account_menu_items' );
@madhvendras84
madhvendras84 / backup for the extra codes
Created September 4, 2023 07:18
Adding timezone text directly in this plugin => prorevuz.biz => wp-content/plugins/bookingpress-woocommerce/core/classes
<?php
if (!class_exists('bookingpress_woocommerce')) {
class bookingpress_woocommerce {
function __construct() {
register_activation_hook(BOOKINGPRESS_WOOCOMMERCE_DIR.'/bookingpress-woocommerce.php', array('bookingpress_woocommerce', 'install'));
register_uninstall_hook(BOOKINGPRESS_WOOCOMMERCE_DIR.'/bookingpress-woocommerce.php', array('bookingpress_woocommerce', 'uninstall'));
//Admiin notices
add_action('admin_notices', array($this, 'bookingpress_admin_notices'));
[memb_has_any_tag tagid=20684]
<div id="iyg-wrapper">
<h4>Australia</h4>
<div id="iyg-btn-wrapper">
<a href="https://cw253.infusionsoft.app/app/form/member-guest-voucher-booking" id="invoice-contact-us-button" rel="noopener">Invite Your Guest</a>
<a href="https://cw253.infusionsoft.app/app/form/member-only-voucher-booking-2" id="invoice-contact-us-button" rel="noopener">Register Yourself</a>
</div>
</div>
[/memb_has_any_tag]
[memb_has_any_tag tagid="Current Bx AUS Member"]
<h2>Paid Invoices</h2>
<hr>
<table class="table" width="100%">
<thead>
<td>Invoice #</td>
<td>Status</td>
<td>Description</td>
<td>Invoice Total</td>
<td>Date Issued</td>
Replace this line in your wp-config.php file:
define('WP_DEBUG', false);
with this:
ini_set('display_errors','Off');
ini_set('error_reporting', E_ALL );
define('WP_DEBUG', false);
define('WP_DEBUG_DISPLAY', false);
@madhvendras84
madhvendras84 / edubin theme footer.php
Created July 5, 2023 16:18
manually added an elementor course carousel in the edubin theme learndash single course page
@madhvendras84
madhvendras84 / Buddyboss login redirect
Created June 7, 2023 07:22
Place this code in child theme >> functions.php
/*
***************************************************************************************************
***************************** Login redirect on welcome page **************************************
***************************************************************************************************
*/
function my_login_redirect( $redirect_to, $request, $user ) {
$redirect_to = site_url("welcome");
return $redirect_to;
}
<style>
#dashboard-event-calender-grid header.tribe-events-header, #dashboard-event-calender-grid h2.tribe-events-calendar-list__month-separator, #dashboard-event-calender-grid .tribe-events-c-subscribe-dropdown__container, #dashboard-event-calender-grid nav.tribe-events-calendar-list-nav.tribe-events-c-nav, #dashboard-event-calender-grid .tribe-events-calendar-list__event-description p, #dashboard-event-calender-grid span.tribe-events-calendar-series-archive__container svg {
display: none !important;
}
#dashboard-event-calender-grid .tribe-common-l-container.tribe-events-l-container {
min-height: unset !important;
padding: 0 !important;
}
#dashboard-event-calender-grid .tribe-events-calendar-list {
display: flex;