Skip to content

Instantly share code, notes, and snippets.

@Tommy-b
Tommy-b / Simple Swup-GSAP-Wordress example
Last active June 25, 2023 15:14
Basic setup for using Swup page transitions and GSAP in a Wordpress site
Basic setup for using Swup page transitions and GSAP in a Wordpress site.
Notes (Will update as time goes on) :
1. Be sure that if you use ID's on elements there is only one throughout the site.
Since there is no actual page load Chrome has issues determining that you are not
using the same ID multiple times.
@p3t3r67x0
p3t3r67x0 / pseudo_elements.md
Last active February 24, 2026 02:08
A CSS pseudo-element is used to style specified parts of an element. In some cases you can style native HTML controls with vendor specific pseudo-elements. Here you will find an list of cross browser specific pseudo-element selectors.

Styling native elements

Native HTML controls are a challenge to style. You can style any element in the web platform that uses Shadow DOM with a pseudo element ::pseudo-element or the /deep/ path selector.

video::webkit-media-controls-timeline {
  background-color: lime;
}

video /deep/ input[type=range] {
@roytanck
roytanck / rt-force-cache-refresh.php
Last active August 29, 2015 14:02
WordPress plugin to force cleaning of expired WP Super Cache files
<?php
/**
* Plugin Name: RT Force Cache Refresh
* Plugin URI: http://www.this-play.nl
* Description: Periodically deletes expired WP Super Cache files using WP-Cron
* Version: 0.8
* Author: Roy Tanck
* Author URI: http://www.this-play.nl
* License: GPL2
*/
@DevinWalker
DevinWalker / gravity-forms_bootstrap
Last active January 25, 2025 10:29
Gravity Forms Twitter Bootstrap CSS Styles Turn OFF Gravity Forms CSS Turn On HTML5 See: http://roots.io/style-gravity-forms-with-bootstrap/
/* ------------------------------------
Gravity Forms
---------------------------------------*/
.gform_wrapper ul { padding-left: 0; list-style: none }
.gform_wrapper li { margin-bottom: 15px }
.gform_wrapper form { margin-bottom: 0 }
@helgatheviking
helgatheviking / functions.php
Created July 17, 2013 16:32
A repeating text field for Options Framework
// add this to your theme's functions.php
/*
* Define a custom option type
* this type will repeat some text inputs
*/
function repeat_text_option_type( $option_name, $option, $values ){
$counter = 0;
@dabernathy89
dabernathy89 / gravity-forms-field-groups.php
Created March 13, 2013 19:55
Insert this script into functions.php in your WordPress theme (be cognizant of the opening and closing php tags) to allow field groups in Gravity Forms. The script will create two new field types - Open Group and Close Group. Add classes to your Open Group fields to style your groups. Note that there is a stray (but empty) <li> element created. …
<?php
/*
Insert this script into functions.php in your WordPress theme (be cognizant of the opening and closing php tags) to allow field groups in Gravity Forms. The script will create two new field types - Open Group and Close Group. Add classes to your Open Group fields to style your groups.
Note that there is a stray (but empty) <li> element created. It is given the class "fieldgroup_extra_li" so that you can hide it in your CSS if needed.
*/
add_filter("gform_add_field_buttons", "add_fieldgroup_fields");
function add_fieldgroup_fields($field_groups){
foreach($field_groups as &$group){
@i-scorpion
i-scorpion / README.txt
Created June 18, 2012 12:24
Twitter bootstrap fixed table header using jQuery
Here is a simple jQuery plugin to make a table header fixed on top when window is scrolled.
Using the code from twitter bootstrap documentation page, this code is customized for table header.
Create the table with following layout -
<table class="table-fixed-header">
<thead class="header">
<tr>
<th>Column 1</th>
<th>Column 2</th>
<th>Column 3</th>
@luetkemj
luetkemj / wp-query-ref.php
Last active March 17, 2026 22:23
WP: Query $args
// This gist is now maintained on github at https://github.com/luetkemj/wp-query-ref
<?php
/**
* WordPress Query Comprehensive Reference
* Compiled by luetkemj - luetkemj.github.io
*
* CODEX: http://codex.wordpress.org/Class_Reference/WP_Query#Parameters
* Source: https://core.trac.wordpress.org/browser/tags/4.9.4/src/wp-includes/query.php
*/