Skip to content

Instantly share code, notes, and snippets.

@poripa
poripa / sp-gallery.php
Created January 8, 2017 09:09
Ultimate Member Gallery: Hide the Gallery Tab on the profile page of specific roles
@ultimatemember
ultimatemember / gist:78aac8b268b2c75489f0
Last active August 21, 2024 18:17
Apply your own custom validation to a field
/*
In this code sample, you can learn how to apply custom
validations on any fields you want.
This can be done using these steps:
1. Edit the field in backend (field modal)
2. Where it asks for field validation choose "Custom"
3. Enter a unique validation action name e.g. my_8numbers
@pryley
pryley / UltimateMembersMods
Created May 4, 2015 22:45
This Wordpress plugin adds custom features and modifications to the Ultimate Member plugin family.
<?php
/**
* Plugin Name: Ultimate Member Modifications
* Plugin URI: http://geminilabs.io
* Description: This plugin adds custom features and modifications to the Ultimate Member plugin family.
* Version: 1.0.0
* Author: Gemini Labs
* Author URI: http://geminilabs.io
* License: MIT License
*/
@ultimatemember
ultimatemember / gist:8cdaf61e7bd9de35512c
Last active April 19, 2021 20:35
Extending Ultimate Member Profile Menu using Hooks
/* First we need to extend main profile tabs */
add_filter('um_profile_tabs', 'add_custom_profile_tab', 1000 );
function add_custom_profile_tab( $tabs ) {
$tabs['mycustomtab'] = array(
'name' => 'My custom tab',
'icon' => 'um-faicon-comments',
);
@ipedrazas
ipedrazas / gist:2c93f6e74737d1f8a791
Created September 18, 2014 22:13
List Docker Container Names and IPs
function drips(){
docker ps -q | xargs -n 1 docker inspect --format '{{ .NetworkSettings.IPAddress }} {{ .Name }}' | sed 's/ \// /'
}