Skip to content

Instantly share code, notes, and snippets.

Where is the average fold

Screen Resolution Visitor Avg. Min. Max.
1680x1050 (36%) 1508x845 582x623 1680x989
1440x900 (36%) 1354x752 704x549 1140x836
1600x900 (36%) 1485x741 963x410 1600x809
1920x1200 (36%) 1559x952 944x696 1920x1138
2560x1440 (36%) 1631x1109 966x697 2560x1342
@simondahla
simondahla / increase-tracked-clicks-vwo-heatmaps.html
Last active August 29, 2015 14:06
You can increase the number of clicks for a session to be used for mapping heatmaps and clickmaps. The default is number is 3. If you want to record more clicks from a session, let's say: you wish to increase the number of clicks to 10 (or any number), then define the following java script variable above VWO tracking code. Read more about VWO He…
<script type='text/javascript'>
_vwo_clicks=10; // Change this number accordingly to the number of clicks you want to track in your VWO heatmaps/clickmaps
</script>
@simondahla
simondahla / pageres_README.md
Last active August 29, 2015 14:06
Document your work, changes – Capture screenshots of websites in various resolutions.

Document your work and changes! – Capture screenshots of websites in various resolutions.

  1. Install Pageres via npm install --global pageres-cli
  2. Download the textfile (above) with the most poplular screen resolutions and put it the desired folder OR go in to your Google Analytics account and grab the most popular screen resolutions for your site
  3. Run pageres example.com --crop &lt; res.txt and you will have a bunch of screenshots of your site.

Since we have observed that [problem description]
by [data/observation method]
we want to [make this change]
which should lead to [desired change in behavior]
The effect will be measured by [KPI(s) or metrics that will change]

AB-test workflow

These instructions describes an AB-test development for OSX

##Dependencies & Instructions

  1. Install Homebrew through your command line ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install master/install)"

  2. Install Git via Homebrew. Run brew install git in your command line.

#templatePreheader{
background-color:#e61c1c;
border-top:0;
border-bottom:0;
}
.preheaderContainer .mcnTextContent,.preheaderContainer .mcnTextContent p{
color:#fefefe;
font-family:Helvetica;
font-size:9px;
line-height:100%;
@simondahla
simondahla / gtm-noindex-tag.html
Last active November 6, 2015 08:19
If running an split test (AB-test redirecting the traffic to different pages) use this to exclude the variation(s) so you don't get punished for duplicate content. This should work in the same way as described in this blog post: http://dah.la/1RAIrzJ
<script>
var m = document.createElement('meta');
m.name = 'robots';
m.content = 'noindex, nofollow';
document.head.appendChild(m);
</script>
@simondahla
simondahla / eid-widget-fix.js
Last active December 18, 2015 09:49
discount code parser for eventbee widget
// Get discount code in Eventbee widget
var eventID = ''; //Set your event ID here
//Function to get the code from the browser url
function getParameterByName(name)
{
name = name.replace(/[\[]/, "\\\[").replace(/[\]]/, "\\\]");
var regexS = "[\\?&]" + name + "=([^&#]*)";
var regex = new RegExp(regexS);
var results = regex.exec(window.location.search);
@simondahla
simondahla / vwo-jquery-noduplicate.js
Last active December 19, 2015 07:19
Workaround for VWO Duplicate content due to jQuery loop
if (!vwo_$('#newUniqeIdentifier').length) {
// Do your vwo_$ stuff here
// vwo_$('<h1>Foo</h1>').replaceWith( '<h1 id="newUniqeIdentifier">Bar</h1>' );
}
setTimeout(function(){
// tweet button
var tweeter = $('<a href="https://twitter.com/share" class="twitter-share-button">Tweet</a>');
// facebook 'like' button
var fbLike = $('<iframe class="fbLike" src="http://www.facebook.com/plugins/like.php?href=bestofconversion.com&amp;send=false&amp;layout=standard&amp;width=450&amp;show_faces=false&amp;font=arial&amp;action=like&amp;height=35&amp;colorscheme=light&amp;layout=button_count&amp;appId=2398652648"></iframe>');
$('.social').append(fbLike, tweeter);
!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0];if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src="http://platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");
window.getComputedStyle(fbLike[0]).getPropertyValue('top');