Skip to content

Instantly share code, notes, and snippets.

View rustyeddy's full-sized avatar
💭
Hacking

Rusty Eddy rustyeddy

💭
Hacking
View GitHub Profile
@rustyeddy
rustyeddy / display_child_pages_with_thumb.php
Last active December 14, 2015 06:39
This function will display all children of a page along with the thumbnail. I have it setup with div class that will print them in a 2 wide grid. It calls the medium size. A couple of these things should be paramatized (is that a word?). :)
function lpo_display_child_pages_with_thumbs()
{
global $wpdb;
global $post;
/*
* create a query that will locate all children of THIS page keeping
* the ORDER in specified in this page.
*/
$sql = "SELECT * FROM $wpdb->posts WHERE post_parent = " .
@rustyeddy
rustyeddy / .emacs
Last active December 13, 2015 23:09
A new, VERY whittled down version of my .emacs file.
;; .emacs
;;; uncomment this line to disable loading of "default.el" at startup
;; (setq inhibit-default-init t)
;; turn on font-lock mode
(when (fboundp 'global-font-lock-mode)
(global-font-lock-mode t))
;; enable visual feedback on selections
*~
diff
*.diff
patch
*.patch
error_log
foo
remove-me
/*
* We have a 220x220px area with 50% rounded radius, effectively
* creating a circle. We'll color the circle with a modern mellow
* cool blue with a bold white font smack in the middle.
*/
.lakepark-round
{
font-size: 36px;
font-weight: 800;
@rustyeddy
rustyeddy / contact-info.html
Last active December 12, 2015 05:38
HTML Contact block with classes
<div class='contact-block'>
<div class='contact-block-wrap'>
<img src='http://example/logo.jpg' />
</div>
<div class='contact-block-inner contact-address'>
<p>Somewhere Road</p>
<p>My Town, CA 900001</p>
</div>
<div class='contact-block-inner contact-block-phones'>
@rustyeddy
rustyeddy / html.php
Created January 26, 2013 16:44
HTML helper functions to make life just a little bit easier.
<?php
function href($url, $anchor, $class = null)
{
$html = "<a ";
if ($class != null) {
$html .= 'class="' . $class . "' ";
}
$html .= 'href="' . $url . '"' . ">" . $anchor . "</a>";