Skip to content

Instantly share code, notes, and snippets.

View matthendrix's full-sized avatar

Matt Emery matthendrix

  • NSW, Australia
View GitHub Profile
@matthendrix
matthendrix / pardot-form-handler-iframe.html
Last active February 16, 2016 12:14 — forked from afischoff/pardot-form-handler-iframe.html
Example of using a hidden iframe to pass data to a Pardot form handler before continuing with normal form submission.
<html>
<head>
<title>Pardot Example Form Handler Submit</title>
<!-- Include jQuery -->
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
<!-- Post to Pardot function -->
<script type="text/javascript">
// set the pardot form handler url and form element id
@matthendrix
matthendrix / bookmarklet.js
Last active September 29, 2017 11:45
A bookmarklet that can switch between local and live servers.
javascript:(function(){
var matches = {
'domain1':'www.domain1.com.au',
'whatever':'www.whatever.com.au',
'mylocalserver':'www.myliveserver.com.au'
},
matchesReversed = {};
for(var v in matches) {
matchesReversed[matches[v]] = v;
}