Skip to content

Instantly share code, notes, and snippets.

View ethiel88's full-sized avatar

Villegas ethiel88

View GitHub Profile
@ethiel88
ethiel88 / Rewrite.php
Created April 1, 2021 21:33
Fix Memory exhausted DIVI and The events calendar plugin
// wp-content/plugins/the-events-calendar/src/Tribe/Views/V2/Rewrite.php
//This file is causing an infinite loop because never ends, seems to be recursive so I've added this one line 71
if(!in_array($encoded, $base_group)) // <--- This line I've added
$base_group[] = $encoded;
@ethiel88
ethiel88 / remove_tabs_on_profile_page_ultimate_member.txt
Created September 13, 2019 15:28
Ultimate Member - Remove tabs on profile page
<?php
add_filter('um_profile_tabs', 'pages_tab', 1000 );
function pages_tab( $tabs ) {
unset($tabs['posts']);
unset($tabs['comments']);
return $tabs;
}
@ethiel88
ethiel88 / add_custom_field_to_ultimate_member_account.txt
Created September 13, 2019 15:25
Ultimate Member - adding custom fields in account page, edit and save working ok!
add_action('um_after_account_general', 'showExtraFields', 100);
function showExtraFields()
{
$custom_fields = [
"razon_social" => "Razón Social",
"nit" => "NIT",
"ci" => "CI",
"phone_number" => "Número de teléfono fijo",
"mobile_number" => "Número de teléfono móvil",
@ethiel88
ethiel88 / add_custom_field_to_ultimate_member_account.txt
Created September 13, 2019 15:25
Ultimate Member - adding custom fields in account page, edit and save working ok!
add_action('um_after_account_general', 'showExtraFields', 100);
function showExtraFields()
{
$custom_fields = [
"razon_social" => "Razón Social",
"nit" => "NIT",
"ci" => "CI",
"phone_number" => "Número de teléfono fijo",
"mobile_number" => "Número de teléfono móvil",
@ethiel88
ethiel88 / reset_evaluation_jetbrains.sh
Created August 26, 2019 04:19
Reinicia el periodo de evaluación de productos jetbrains - Probado en las versiones 2018.*, 2019.*
#!/bin/bash
############################################################
# Reinicia el periodo de evaluación de productos jetbrains #
# Probado en las versiones 2018.*, 2019.* #
# Luis Villegas ethiel88@gmail.com #
############################################################
CYAN='\033[0;36m'
GREEN='\033[0;32m'
@ethiel88
ethiel88 / agregar_resolucion_linux.txt
Created July 15, 2019 04:05
Resolución y escala de las fuentes en linux y programas
# First we need to get the modeline string for xrandr
# Luckily, the tool "gtf" will help you calculate it.
# All you have to do is to pass the resolution & the-
# refresh-rate as the command parameters:
gtf 1920 1080 60
# In this case, the horizontal resolution is 1920px the
# vertical resolution is 1080px & refresh-rate is 60Hz.
# IMPORTANT: BE SURE THE MONITOR SUPPORTS THE RESOLUTION
@ethiel88
ethiel88 / lamp_postgres_manjaro.txt
Last active June 17, 2019 05:37 — forked from pokisin/instalacion.md
LAMP, POSTGRES y Host Virtuales con y sin SSL EN Manjaro/Arch
LAMP, POSTGRES y Host Virtuales con y sin SSL EN Manjaro/Arch
===== ======== = ==== ========= === = === === == ============
Iniciamos una terminal con privilegios de superusuario
$ sudo bash
Actualizamos la base de datos de los paquetes
# pacman -Syu
Apache