Skip to content

Instantly share code, notes, and snippets.

marco-van-zomeren

Block or report user

Report or block marco-van-zomeren

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@marco-van-zomeren
marco-van-zomeren / safari_border-radius_overflow-hidden_hover-fix.css
Last active Feb 2, 2019
Safari border-radius + overflow: hidden + hover fix
View safari_border-radius_overflow-hidden_hover-fix.css
.block__image-container {
background-image: ... ;
border-radius: 5px;
overflow:hidden;
-webkit-mask-image: -webkit-radial-gradient(white, black);
}
View css-line-arrow.scss
// ARROW
$arrow-size: 31px;
$arrow-border: 1.2px;
.read-more,
a[rel~="next"],
a[rel~="prev"] {
position: relative;
i {
View fade-in-on-scroll-in-viewport.js
// FADEIN
var animateHTML = function() {
var elems;
var windowHeight;
function init() {
elems = document.querySelectorAll('.fx_fadeInUp');
windowHeight = window.innerHeight;
addEventHandlers();
checkPosition();
}
View custom-social-share-buttons.js
// SHARE PAGE
$(document).ready(function () {
$('.js__share-page a.share-page__on-facebook').click(function () {
var link = $(location).attr('href');
var facebookUrl = "https://www.facebook.com/sharer/sharer.php?u=" + link;
window.open(facebookUrl);
});
$('.js__share-page a.share-page__on-twitter').click(function () {
var link = $(location).attr('href');
var twitterUrl = "https://twitter.com/intent/tweet?url=" + link + '&text=' + "Hey, bekijk eens:" + link;
View wordpress-gerelateerde-posts.php
<pre><code class="language-html code">
<?php
$related = get_posts( array( 'category__in' =>
wp_get_post_categories($post->ID), 'numberposts' => 5,
'post__not_in' => array($post->ID) ) );
if( $related ) foreach( $related as $post ) {
setup_postdata($post); ?>
<ul>
<li>
<a href="<?php the_permalink() ?>" title="<?php the_title(); ?>">
You can’t perform that action at this time.