Skip to content

Instantly share code, notes, and snippets.

View alijaffar's full-sized avatar
💭
I may be slow to respond.

Ali alijaffar

💭
I may be slow to respond.
  • United States
View GitHub Profile
@mozzadrella
mozzadrella / mozzadrellas-school-of-mgmt.md
Last active May 3, 2023 15:23
Works cited and consulted for "An OS for Life"

Mozzadrella's School of Management

The Reading List

These books span across the domains of management, psychology, learning design, and business. They shaped my point of view on how to tell a story, understand human motivation, consider the role of power in organizations, show up as a feminist boss, and be more self-aware. All of those things are interconnected.

Armbrust, Jennifer. The Business Birthing Handbook. Are you tired? It's likely because you've been chewed up by gnarly demands on your body, or toxic notions of "growth" or "success." Armbrust reframes business as a creative, nurturing process.

Conscious Leadership Group. The 15 Committments of Conscious Leadership. If you are new to management, start here.

Evans, Julia. Help! I have a manager!. If you aren't getting what you want from your manager or leader, t

import React from "react";
import { Link } from "react-router-dom";
export function createResource(getPromise) {
let cache = {};
let inflight = {};
let errors = {};
function load(key) {
inflight[key] = getPromise(key)
@lhstraathof
lhstraathof / directus_hugo
Created September 23, 2017 17:55
Get data from DIrectus CMS in Hugo
<ul>
{{ $data := getJSON "https://cms.dev:8890/api/1.1/tables/settings/rows?access_token=vpqBqeRX4CGw2OgDdZxv9H26Rw8mIo4Z" }}
{{ range $data.data }}
{{ if .site_name }}
<li>{{ .site_name }}</li>
{{ end }}
{{ end }}
</ul>
@champsupertramp
champsupertramp / Ultimate Member - adding custom fields in account page and tab
Last active October 14, 2023 19:18
Ultimate Member - adding custom fields in account page and tab
<?php
/* Add fields to account page */
add_action('um_after_account_general', 'showExtraFields', 100);
function showExtraFields()
{
$custom_fields = [
"alternate_email" => "Permanent E-mail Address",
"major" => "Major",
"minor" => "Minor",
"gpa" => "GPA",
@andrewwoods
andrewwoods / resources.md
Last active December 16, 2016 16:15
PHP resources

PHP Resources

This gist has been converted to a repository called PHP Resoures Repo that you can fork and pull request to your heart's content!

May your coffee always be warm, your code always work, and the force be with you

@AmirHossein
AmirHossein / coordinatestoname.js
Last active December 25, 2023 11:15
Get City and Country name by coordinates via Google Maps api
// Demo: http://jsfiddle.net/xuyp8qb5/
// Note: You need Google Map API Key to run demo; bit.ly/2pBgToW
var latlng;
latlng = new google.maps.LatLng(40.730885, -73.997383); // New York, US
//latlng = new google.maps.LatLng(37.990849233935194, 23.738339349999933); // Athens, GR
//latlng = new google.maps.LatLng(48.8567, 2.3508); // Paris, FR
//latlng = new google.maps.LatLng(47.98247572667902, -102.49018710000001); // New Town, US
//latlng = new google.maps.LatLng(35.44448406385493, 50.99001635390618); // Parand, Tehran, IR
//latlng = new google.maps.LatLng(34.66431108560504, 50.89113940078118); // Saveh, Markazi, IR
@cuibonobo
cuibonobo / centos_python_install.md
Last active April 30, 2024 13:13
Install Python 2.7.15 on CentOS 6

These instructions were mostly taken from here, though I've modified them to install Python 2.7.15 and the latest setuptools package.

# Install dependencies
yum groupinstall -y 'development tools'
yum install -y zlib-devel bzip2-devel openssl-devel xz-libs wget

# Download the Python source and unpack it
wget https://www.python.org/ftp/python/2.7.15/Python-2.7.15.tgz
tar -xvzf Python-2.7.15.tgz
@magnific0
magnific0 / wp_usermeta.md
Last active June 16, 2023 05:28
Show and Edit User Meta in Wordpress

Show and Edit User Meta in Wordpress

Description

This simple procedure will allow you to:

  1. Display user meta fields under in the user list as additional columns (Users > All Users).
  2. Display these fields on user profiles.
  3. Edit these fields under user edit.

This method works completely without plugins and involves just some functions and hooks in functions.php. Plugins like "User Meta Display" achieve this to some level, but treat custom meta fields completely different from the regular fields. They are shown and edited in seperate environment and fail to show the meta data is a table list. This method integrates custom user meta along with regular user (meta).

@thomasfr
thomasfr / Git push deployment in 7 easy steps.md
Last active May 1, 2024 23:17
7 easy steps to automated git push deployments. With small and configurable bash only post-receive hook
@nicoleslaw
nicoleslaw / 1_Tiny_Content_Framework.md
Last active January 23, 2024 02:28
Tiny Content Framework

Tiny Content Framework

About the project

This is a tiny content strategy framework focused on goals, messages, and branding. This is not a checklist. Use what you need and scrap the rest. Rewrite it or add to it. These topics should help you get to the bottom of things with clients and other people you work with.

Give me feedback on Twitter (@nicoleslaw) or by email (nicole@nicolefenton.com).

Contents