Skip to content

Instantly share code, notes, and snippets.

Charles Peterson Artistan

Block or report user

Report or block Artistan

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
View widget-template.js
(function($){
$.widget("ui.mywidget", {
options: {
autoOpen: true
},
_create: function(){
// by default, consider this thing closed.
@Artistan
Artistan / .bash_profile
Created Nov 15, 2013
bash_profile settings
View .bash_profile
# USE cg img; // will show 2 lines before and 15 lines after match.
alias cg="find . -path '*/.svn/*' -prune -o -path '*/.git/*' -prune -o -path '*compiled*' -prune -o -type f -print | xargs -e grep -A 15 -B 2 --color -rnisIe "
# USE f img;
alias f="find . -path '*/.svn/*' -prune -o -path '*/.git/*' -prune -o -path '*compiled*' -prune -o -type f -print | xargs -e grep --color -rnisIe "
View find_and_replace.sh
f 'findthistext' | xargs sed -i -e 's/findthistext/replacewiththistext/g';
# replace members/upload.php with upload.php
f 'members\/upload\.php' | xargs sed -i -e 's/members\/upload\.php/upload\.php/g';
# using my .bash_profile
# prevents changes to .svn and .git files!!!
f 'findthistext' | xargs sed -i -e 's/findthistext/replacewiththistext/g';
View pagination.twig
{#
You need the following variables:
paginationCurrentFilters: an associative array that contains the current settings of the page like search, filters, etc. For example {% set paginationCurrentFilters = { ‘search’: search, ‘filter_by_is_active’: filter_by_is_active } %}, so it can be easy for us to merge the pagination with these filters.
paginationCurrentPage : the current page you are in
paginationRouteName : the route name of the path that paginates files
paginationTotal : The paginationTotal number of pages (ceil(found_entities/items_per_page))
paginationLastPage : represents the paginationTotal number of existing pages
paginationExtremePagesLimit : the number of first and last pages to be displayed
paginationNearbyPagesLimit : the number of pages that are displayed around the active page
View free_email_provider_domains.txt
hitmail.com
rxdoc.biz
cox.com
126.net
126.com
comast.com
comast.net
yandex.com
wegas.ru
twc.com
@Artistan
Artistan / free-email-domains.php
Last active Aug 29, 2015
Php array list of free email domains
View free-email-domains.php
return ['free'=>['hitmail.com','rxdoc.biz','cox.com','126.net','126.com','comast.com','comast.net','yandex.com','wegas.ru','twc.com','charter.com','outlook.com','gmx.com','.ddns.org','.findhere.com','.freeservers.com','.zzn.com','1033edge.com','11mail.com','123.com','123box.net','123india.com','123mail.cl','123qwe.co.uk','150ml.com','15meg4free.com','163.com','1coolplace.com','1freeemail.com','1funplace.com','1internetdrive.com','1mail.net','1me.net','1mum.com','1musicrow.com','1netdrive.com','1nsyncfan.com','1under.com','1webave.com','1webhighway.com','212.com','24horas.com','2911.net','2bmail.co.uk','2d2i.com','2die4.com','3000.it','321media.com','37.com','3ammagazine.com','3dmail.com','3email.com','3xl.net','444.net','4email.com','4email.net','4mg.com','4newyork.com','4x4man.com','5iron.com','5star.com','88.am','8848.net','888.nu','97rock.com','aaamail.zzn.com','aamail.net','aaronkwok.net','abbeyroadlondon.co.uk','abcflash.net','abdulnour.com','aberystwyth.com','abolition-now.com','about.com','academycouga
View lessWatch.sh
#!/bin/bash
while true;
do N=`find -name "*.less" `;
inotifywait -qe modify $N ;
for f in $N;
do lessc $f ${f%.*}.css;
done;
done;
@Artistan
Artistan / main.less.sh
Created Apr 17, 2014
main.css less compiler
View main.less.sh
#!/bin/bash
while true;
do N=`find -name "*.less" `;
inotifywait -qe modify $N ;
for f in $N;
do lessc main.less main.css;
done;
done;
@Artistan
Artistan / dabblet.css
Created Feb 21, 2015
Generate repeating hexagonal pattern with CSS3 (SO) - 1 element/ hexagon !!!
View dabblet.css
/**
* Generate repeating hexagonal pattern with CSS3 (SO) - 1 element/ hexagon !!!
* http://stackoverflow.com/q/10062887/1397351
*/
* { box-sizing: border-box; margin: 0; padding: 0; }
.row { margin: -18.5% 0; text-align: center; }
.row:first-child { margin-top: 2.25%; }
.hexagon {
position: relative;
display: inline-block;
@Artistan
Artistan / dabblet.css
Created Feb 21, 2015
Generate repeating hexagonal pattern with CSS3 (SO) - 1 element/ hexagon !!!
View dabblet.css
/**
* Generate repeating hexagonal pattern with CSS3 (SO) - 1 element/ hexagon !!!
* http://stackoverflow.com/q/10062887/1397351
*/
* { box-sizing: border-box; margin: 0; padding: 0; }
.row { margin: -18.5% 0; text-align: center; }
.row:first-child { margin-top: 2.25%; }
.hexagon {
position: relative;
display: inline-block;
You can’t perform that action at this time.