Skip to content

Instantly share code, notes, and snippets.

View charleslouis's full-sized avatar

okcharlo charleslouis

View GitHub Profile
@aarongustafson
aarongustafson / responsive-iframes.css
Created October 25, 2011 17:07
Responsive iFrames with jQuery
iframe {
max-width: 100%;
}
@evilmarty
evilmarty / dabblet.css
Created June 29, 2012 23:12
styling the calendar indicator for webkit
html {
background: #f06;
background: linear-gradient(90deg, #cceecc,#eeeeee);
min-height: 100%;
}
input[type=date] {
background: #ccc;
background: linear-gradient(90deg, #ddd, #ccc);
border: 3px solid #eee;
border-radius: 20px;
@imath
imath / imath-pm-friends-only.php
Last active May 3, 2023 06:24
I was writing my second BuddyPress tutorial for wpformation.com when i realized it could be helpful for a community admin to restrict private messages to friends only...
<?php
/*** beginning of the code to paste in your functions.php ***/
function imath_pm_button_only_if_friends( $button ) {
if( is_super_admin() )
return $button;
if( 'is_friend' != friends_check_friendship_status( bp_displayed_user_id(), bp_loggedin_user_id() ) )
return false;
@charleslouis
charleslouis / custom-search-acf-wordpress.php
Last active December 15, 2023 09:11
PHP - Wordpress - Search - wordpress custom search function that encompasses ACF/advanced custom fields and taxonomies and split expression before request
<?php
/**
* [list_searcheable_acf list all the custom fields we want to include in our search query]
* @return [array] [list of custom fields]
*/
function list_searcheable_acf(){
$list_searcheable_acf = array("title", "sub_title", "excerpt_short", "excerpt_long", "xyz", "myACF");
return $list_searcheable_acf;
}
@zishe
zishe / angular-pushstate-support.md
Last active May 30, 2020 05:06
Using grunt and Angular with pushstate support!
title author layout categories
Using grunt and angular with pushstate support
Blackjid
post
grunt
angularjs
yeoman
@KonradIT
KonradIT / readme.md
Last active September 25, 2023 01:55
GoPro Studio for Linux
@pricejn2
pricejn2 / gandi_simple_hosting_drush.sh
Created June 18, 2014 16:37
Gandi Simple Hosting Drush install
cd tmp
wget https://github.com/drush-ops/drush/archive/6.3.0.zip
unzip 6.3.0.zip
rm -rf 6.3.0.zip
mv drush-6.3.0 ~/var/php/admin/
cd ~/var/php/admin/
mv drush-6.3.0 drush
chmod 755 drush/drush
chmod 755 drush/drush.php
nano ~/etc/bash/bashrc
@mathpere
mathpere / config.json
Created November 18, 2014 18:35
PayZen with NodeJS
{
"payZen": {
"url": "https://secure.payzen.eu/vads-payment/",
"certificat": "XXXXXXXXX",
"vads_site_id": "YYYYYYYY",
"vads_version": "V2",
"vads_ctx_mode": "TEST"
}
}
@ssgonchar
ssgonchar / installer_.stylelintrc
Created April 19, 2016 11:15
Install and run: jshint, jslint, jscs, stylehint, htmlhint.
{
"rules": {
"at-rule-empty-line-before": "always"|"never",
"at-rule-name-case": "lower"|"upper",
"at-rule-no-vendor-prefix": true,
"at-rule-semicolon-newline-after": "always",
"block-closing-brace-newline-after": "always"|"always-single-line"|"never-single-line"|"always-multi-line"|"never-multi-line",
"block-closing-brace-newline-before": "always"|"always-multi-line"|"never-multi-line",
"block-closing-brace-space-after": "always"|"always-single-line"|"never-single-line"|"always-multi-line"|"never-multi-line",
"block-closing-brace-space-before": "always"|"never"|"always-single-line"|"never-single-line"|"always-multi-line"|"never-multi-line",
@schalkburger
schalkburger / sage_favicons.php
Last active January 16, 2020 01:33
Roots Sage Favicons
/**
* Load favicons
* Place icons in the theme images directory. Want more? http://realfavicongenerator.net/
*/
function sage_favicons() {
echo '<link rel="apple-touch-icon" sizes="57x57" href="'. get_template_directory_uri() .'/dist/images/apple-touch-icon-57x57.png">';echo "\n";
echo '<link rel="apple-touch-icon" sizes="60x60" href="'. get_template_directory_uri() .'/dist/images/apple-touch-icon-60x60.png">';echo "\n";
echo '<link rel="apple-touch-icon" sizes="72x72" href="'. get_template_directory_uri() .'/dist/images/apple-touch-icon-72x72.png">';echo "\n";
echo '<link rel="apple-touch-icon" sizes="76x76" href="'. get_template_directory_uri() .'/dist/images/apple-touch-icon-76x76.png">';echo "\n";
echo '<link rel="apple-touch-icon" sizes="114x114" href="'. get_template_directory_uri() .'/dist/images/apple-touch-icon-114x114.png">';echo "\n";