Skip to content

Instantly share code, notes, and snippets.

Avatar
🤓
Working on Mautic!

Ruth Cheesley RCheesley

🤓
Working on Mautic!
View GitHub Profile
@opencoca
opencoca / mautic_warmup.sh
Created Mar 18, 2020
Mautic Perms and Cache warm up
View mautic_warmup.sh
cd /var/www/mautic
mkdir app/spool/
find . -type d -exec chmod 755 {} \;
find . -type f -exec chmod 644 {} \;
chmod -R g+w app/cache/
chmod -R g+w app/logs/
chmod -R g+w app/config/
chmod -R g+w media/files/
chmod -R g+w media/images/
chmod -R g+w translations/
@tatianamac
tatianamac / tatiana-mac-speaker-rider.md
Last active Sep 15, 2020
Tatiana Mac's Speaker Rider
View tatiana-mac-speaker-rider.md

Speaker Rider

by Tatiana Mac

Before I'll agree to a speaking event, I try to do as much research I can around the event to ensure it aligns with my ethos. I want to share this in case it's helpful to any other speakers.

👐 Speaking comes with immense privilege. I am grateful to all the conference organisers who have brilliantly hosted me. I would love to continue to exercise this privilege to speak at conferences, and use this privilege to make the landscape more accessible and beneficial to tech's most marginalised and suppressed communities.

😫 I wish I didn't have to, but this is long because I provide a lot of explanations for those of you who never had to consider these things. And I will be honest, most thoughtful conferences I've attended check most of these boxes intrinsically, particularly when conference runners are experienced speakers. They get it.

1️⃣ All of these are based on my own ethos. I don't wish to or attempt to speak on behalf of all conference speake

@ChgoChad
ChgoChad / commands.php
Last active Jul 31, 2020 — forked from escopecz/commands.php
Script to run Mautic (https://mautic.org) commands from a URL.
View commands.php
<?php
if (!isset($_GET['ILoveMautic'])) {
echo 'The secret phrase is wrong.';
die;
}
$link = "https://$_SERVER[HTTP_HOST]$_SERVER[REQUEST_URI]";
$allowedTasks = array(
'cache:clear',
@k127
k127 / page.html.php
Created Aug 19, 2016
A simple minimal example for preprocessing PHP template data
View page.html.php
<?php
// We just preprocess some data to use for the template.
// For what we want to show, it is not important what we're doing here exactly,
// rather than the fact that this cannot be done inside a Twig template,
// which is where this PHP HTML template should be convertet to.
if ($image = filter_input(INPUT_GET, 'image') &&
!filter_var($image, FILTER_VALIDATE_URL) === false) {
$image_src = $image;
@Yame-
Yame- / mautic-builder-active.js
Last active Aug 15, 2016
Checking if a Mautic theme (Landing page or E-mail) is being edited through the Builder.
View mautic-builder-active.js
// Checking if we are editting in the Mautic Builder.
if( $('.builder-active', window.parent.document).length ) {
// Do stuff here
}
@bavington
bavington / Site-Search-JSON+LD.html
Last active Feb 24, 2016
Simple JSON+LD Boilerplate for configuring your Site Name and Google Sitelinks Search Box Schema.
View Site-Search-JSON+LD.html
<script type="application/ld+json">
{
"@context": "http://schema.org",
"@type": "WebSite",
// Include your Site name within Google Search Results
"name" : "James' Donuts",
"alternateName" : "James' Donuts Ltd",
"url": "https://www.jamesdonuts.co.uk",
// Enabe the Google Sitelinks Search Box
@abs
abs / gist:c0d598996870dda719b3
Last active Nov 28, 2016
Downloads and installs the startssl CA certs into the global Java keystore
View gist:c0d598996870dda719b3
#!/bin/sh
#
# Downloads and installs the startssl CA certs into the global java keystore
# Author: Klaus Reimer <k@ailis.de>
#
# Check if JAVA_HOME is set
if [ "$JAVA_HOME" = "" ]
then
echo "ERROR: JAVA_HOME must be set."
@molaschi
molaschi / stash_slack_integration.md
Created Jun 4, 2014
Integrate Stash with Slack using webhooks
View stash_slack_integration.md

This is a short article on how we integrate stash and slack in openmind

First of all i assume you have:

  • a working stash installation
  • a repository you to notify slack on pushes
  • stash user with administration priviledges
  • full access to the server (linux) where stash is installed on
  • a team configured on slack
  • slack user with administration priviledges
@redox
redox / base.html.haml
Last active May 16, 2020
Algolia extends HipChat to customer support
View base.html.haml
#chat-box.ubuntu.hidden-xs
.closed
.pull-right
= link_to_function content_tag(:i, nil, class: 'glyphicon glyphicon-chevron-up').html_safe, 'chat.show()'
.m-l-small
= link_to_function 'Chat with us', 'chat.show()'
.opened{style: 'display: none'}
.header
.pull-right
= link_to_function content_tag(:i, nil, class: 'glyphicon glyphicon-plus-sign').html_safe, 'chat.maximize()', class: 'maximize', style: 'display: none'
@thanashyam
thanashyam / sso_login_freshdesk.php
Last active Feb 14, 2020
SSO Login for Freshdesk support portal - PHP Sample Code (Updated)
View sso_login_freshdesk.php
<?php
define('FRESHDESK_SHARED_SECRET','____Place your Single Sign On Shared Secret here_____');
define('FRESHDESK_BASE_URL','http://{{your-account}}.freshdesk.com/'); //With Trailing slashes
function getSSOUrl($strName, $strEmail) {
$timestamp = time();
$to_be_hashed = $strName . FRESHDESK_SHARED_SECRET . $strEmail . $timestamp;
$hash = hash_hmac('md5', $to_be_hashed, FRESHDESK_SHARED_SECRET);
return FRESHDESK_BASE_URL."login/sso/?name=".urlencode($strName)."&email=".urlencode($strEmail)."&timestamp=".$timestamp."&hash=".$hash;
}
You can’t perform that action at this time.