Skip to content

Instantly share code, notes, and snippets.

@svebal
svebal / pluginLoaded.js
Created September 17, 2018 20:29 — forked from siamkreative/pluginLoaded.js
Check if a jQuery plugin is loaded. If not, load it using the $.getScript() function.
jQuery(document).ready(function ($) {
'use strict';
function initModal() {
$('.popup-youtube, .popup-vimeo, .popup-gmaps').magnificPopup({
disableOn: 700,
type: 'iframe',
mainClass: 'mfp-fade',
removalDelay: 160,
@svebal
svebal / Readme.md
Last active October 25, 2021 13:15 — forked from vishalbasnet23/Readme.txt
Custom Activation Link on Sign Up WordPress

Step by step guide.

First Phase:

  1. First create a html form with first name, last name and email field for signing up process.( Remember the action of the form it has to be the page slug of email confirmation page that you will be creating at in next phase. )

Second Phase:

  1. Create a Page ( Remember the slug has to be the same of that of action of the form of phase one ) and assign the template "template-confirmation-mail.php"
  2. This page is responsible for generating unqiue hash key and sending that hash key along with the user's new account credentials to their email.
  3. Remember the link of the activation_link has to the link to the email-verification template, which we will be creating in next phase.
<?php
$url = $_GET['url'];
$allowedurls = array(
'http://developer.yahoo.com',
'http://icant.co.uk'
);
if(in_array($url,$allowedurls)){
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
# Apache Configuration File
# https://github.com/h5bp/server-configs-apache
# (!) Using `.htaccess` files slows down Apache, therefore, if you have access
# to the main server config file (usually called `httpd.conf`), you should add
# this logic there: http://httpd.apache.org/docs/current/howto/htaccess.html.
# ##############################################################################
# # CROSS-ORIGIN RESOURCE SHARING (CORS) #
# ##############################################################################
// ==UserScript==
// @name Ingress Intel: Notify UI
// @namespace https://arantius.com/misc/greasemonkey/
// @description Annotate the Ingress Intel Dashboard with links to control the Ingress Notify app.
// @match http://www.ingress.com/intel*
// @version 1
// @grant none
// ==/UserScript==
//const NOTIFY_SERVER = 'http://localhost:8080/'
@svebal
svebal / modifier.parseXML.php
Created June 10, 2011 05:55 — forked from derpixler/modifier.parseXML.php
Smarty Modifier parseXML to Array
<?php
/**
* Smarty plugin
* @package Smarty
* @subpackage PluginsModifier
*/
/**
* Smarty {$xml|parseXML} function plugin
*
@svebal
svebal / wp-action-plugin-link-hook.php
Created May 25, 2011 09:58 — forked from derpixler/wp-action-plugin-link-hook.php
Wordpress Hook into the plugin action links and filter them!
@svebal
svebal / wp-coustom-term-options.php
Created May 25, 2011 09:55 — forked from derpixler/wp-coustom-term-options.php
Wordpress Hooks to add coustom term Options
<?php
/**
*
* Add only for parents coustom term Options
* @author rene reimann
* @home http://www.rene-reimann.de
*
* @hook category_add_form_fields Hooks into the category edit page
* @hook edit_tag_form_fields Hooks into the category frontpage