Skip to content

Instantly share code, notes, and snippets.

<?php
if ($EmailAddress != "") {
//Varible Setting
$myFile = "subscribers.txt";
//Reading content already there
$fh = fopen($myFile, 'r');
$OldEmailAddresses = fgets($fh);
fclose($fh);
select
HeadNameCounter = HeadOfHouse.NameCounter,
HeadNotMember = case when Relationship.Descr is null or Relationship.Descr not in ('Active Member', 'Affiliate', 'Baptized Child' ) then '*' end,
HeadTitle = HHTitle.Descr,
HeadFirstName = HeadOfHouse.FirstMiddle,
HeadSalutation = HeadOfHouse.Salutation,
HeadLastName = HeadOfHouse.LastName,
HeadSuffix = HHSuffix.Descr,
SpouseNameCounter = Spouses.NameCounter,
@drewrowland
drewrowland / Find IP CentOS
Created October 17, 2013 19:59
Find IP Centos
curl -s ifconfig.me
@font-face {
font-family: 'english_essayregular';
src: url('fonts/english/english_essay-webfont.eot');
src: url('fonts/english/english_essay-webfont.eot?#iefix') format('embedded-opentype'),
url('fonts/english/english_essay-webfont.svg#english_essayregular') format('svg'),
url('fonts/english/english_essay-webfont.woff') format('woff'),
url('fonts/english/english_essay-webfont.ttf') format('truetype');
font-weight: normal;
font-style: normal;
@drewrowland
drewrowland / Collection
Created October 2, 2013 21:34
Collection
//The Collections area is set up like this:
[collections title="Extra Collections"]
[collection_item title="SUMMNER COLLECTIONS 2013" image="image_path.png" content="CONTENT" link="#" text_link="Read more"]
[collection_item title="SUMMNER COLLECTIONS 2013" image="image_path.png" content="CONTENT" link="#" text_link="Read more"]
[collection_item title="SUMMNER COLLECTIONS 2013" image="image_path.png" content="CONTENT" link="#" text_link="Read more"]
[collection_item title="SUMMNER COLLECTIONS 2013" image="image_path.png" content="CONTENT" link="#" text_link="Read more"]
[collection_item title="SUMMNER COLLECTIONS 2013" image="image_path.png" content="CONTENT" link="#" text_link="Read more"]
@drewrowland
drewrowland / 0_reuse_code.js
Created September 27, 2013 20:19
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@drewrowland
drewrowland / CSS Debug
Created June 17, 2013 16:42
CSS Debug The code adds different colored borders to the assets depending on its level. Leave commented out if not needed.
* { outline: 2px dotted red }
* * { outline: 2px dotted green }
* * * { outline: 2px dotted orange }
* * * * { outline: 2px dotted blue }
* * * * * { outline: 1px solid red }
* * * * * * { outline: 1px solid green }
* * * * * * * { outline: 1px solid orange }
* * * * * * * * { outline: 1px solid blue }
@drewrowland
drewrowland / WordPress Image - Theme
Created April 1, 2013 01:52
WordPress Image - Theme
<img src="<?php bloginfo('template_directory'); ?>/images/imagename.png" />
@drewrowland
drewrowland / Change Computer Name - Ubuntu
Created March 12, 2013 20:57
Change Computer Name - Ubuntu
//First step
sudo gedit /etc/hostname
//Second step
sudo gedit /etc/hosts
@drewrowland
drewrowland / Get Like Count Of A Facebook Page
Created March 11, 2013 17:22
Get Like Count Of A Facebook Page
$fb = file_get_contents("http://graph.facebook.com/{Page Name}"); //graph api link to page
$a = json_decode($fb);
$LikesCount = $a->likes; // Page like count
echo $LikesCount;