Skip to content

Instantly share code, notes, and snippets.

@fragje
fragje / recurring.html
Last active December 5, 2016 10:51
Recurring
<!-- Markup -->
<tr><td colspan="8" class="recurring"><p>Abonnementet fortsetter med automatisk månedlig trekk etter at kampanjeutgavene er levert.</p></td></tr>
<!-- Styling -->
<style>
.recurring {
padding: 0 !important;
}
.recurring p {
margin: 0 -10px;
padding: 10px 20px;
@fragje
fragje / style.css
Created June 25, 2015 11:32
ikat-fb-link
/**
* <a href class="facebook-link-page">Besøk IKAT på Facebook</a>
*/
.facebook-link-page {
font-size: 12px;
position: absolute;
top: -52px;
right: 0;
}
@fragje
fragje / index.html
Created May 28, 2015 11:56
Tmp - Related view
<div class="teaser-list-img view view-rel-content view-id-rel_content view-display-id-block_4 block-views-rel-content-block view-dom-id-f9d0b33ad689a2cc1576aa3de782c210">
<h2 class="view-title">Other related content</h2>
<div class="view-content">
<div class="views-row views-row-1 views-row-odd views-row-first">
<img src="http://placehold.it/300x300" alt="">
<h3 class="views-field views-field-title title">
<span class="field-content"><a href="/nb/node/16412">An extended country-by-country reporting standard. A policy proposal to the EU. Volume 2 </a></span>
</h3>
<div class="desc">
<p>Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Morbi commodo, ipsum sed pharetra gravida, orci magna rhoncus neque.</p>
@fragje
fragje / script.js
Created May 1, 2015 15:56
Update list - js
// console log history
var el = document.getElementById("accordion-1").children[0].childNodes[0]
undefined
el
"2015
"
typeof el
"object"
el.nodeValue = 2016
2016
@fragje
fragje / script.js
Created March 31, 2015 13:31
object this
var READMORE = {
body: $('.js-readmore'),
bodyFirstChild: this.body.cildren()[0],
bodyRemainingChildren: function() {
var children = this.body.children();
children = children.splice(0.1);
return children;
}
};
@fragje
fragje / script.js
Created March 12, 2015 13:18
els tracking
<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
ga('create', 'UA-23893312-1', 'auto');
ga('send', 'pageview');
</script>
@fragje
fragje / script.js
Created March 7, 2015 11:29
JS callback examples
// Custom javascript
function fullName(firstName, lastName, callback) {
console.log('My name is ' + firstName + ' ' + lastName);
callback(lastName);
}
var greeting = function(ln) {
console.log("Welcome Mr. " + ln);
}
@fragje
fragje / style.css
Created February 9, 2015 12:53
NG dottet row
.l-row {
border-bottom: 1px dotted #000;
margin-bottom: 15px;
&:last-child {
border-bottom: none;
margin-bottom: 0;
}
}
@fragje
fragje / gist:bd511dd36ea45e1de106
Created January 23, 2015 15:35
fusion-shortcode
[fullwidth backgroundcolor="#eeee22" backgroundimage="" backgroundrepeat="no-repeat" backgroundposition="left top" backgroundattachment="scroll" video_webm="" video_mp4="" video_ogv="" video_preview_image="" overlay_color="" overlay_opacity="0.5" video_mute="yes" video_loop="yes" fade="no" bordersize="0px" bordercolor="" borderstyle="solid" paddingtop="0px" paddingbottom="0px" paddingleft="0px" paddingright="0px" menu_anchor="" equal_height_columns="no" hundred_percent="no" class="" id=""][two_fifth last="no" spacing="yes" background_color="" background_image="" background_repeat="no-repeat" background_position="left top" border_size="0px" border_color="" border_style="" padding="" class="" id=""][imageframe lightbox="no" style_type="none" bordercolor="" bordersize="0px" borderradius="0" stylecolor="" align="center" link="" linktarget="_self" animation_type="0" animation_direction="down" animation_speed="0.1" class="" id=""] [/imageframe][/two_fifth][three_fifth last="yes" spacing="yes" background_color="" ba
@fragje
fragje / style.css
Created January 23, 2015 08:22
FAR table
table {
margin-bottom: .8em;
}
table td,
table th {
padding: .8em;
border: 1px solid #ddd;
}