Skip to content

Instantly share code, notes, and snippets.

View artlung's full-sized avatar

Joe Crawford artlung

View GitHub Profile
artlung / DHTML.js
Created May 29, 2024 01:36
I do not miss this.
function show(object,x,y) {
if (document.all && document.all[object]) {
document.all[object].style.left = x+'px';
document.all[object] = y+'px';
document.all[object].style.zIndex = AlwaysTopmostZ;
document.all[object].style.color = '#000';
document.all[object].style.visibility = 'visible';
else if (document.layers && document.layers[object] != null) {
Plugin Name: Customize Feed Content
Description: I'm looking for a theme-independent plug-in that will let me customize my blog post excerpts for my RSS feed. I would like to be able to show the featured image and customize the length of the preview, as well as add a link underneath the excerpt for a viewer to click on to see the original article.
Version: 1.0
Author: artlung
class CustomizeFeedContent {
artlung / happyscribe.com_molly_white_interview_transcript.txt
Last active May 23, 2024 18:37
Entering a New Phase of the Web, with Citation Needed’s Molly White
(Transcript made with
[00:00:02.240] Welcome to Dotsocial, the first podcast to explore the
world of decentralized social media. Each episode, host Mike McHieu
talks to a leader in this movement, someone who sees the Fediverse's
tremendous potential and understands that this could be the internet's
$current_dir = dirname(__FILE__);
// load wordpress functions
require_once( $current_dir . '/../../../wp-load.php');
$years = range(2001, date('Y'));
$ignored_permalinks = [
artlung / excerpt.php
Created March 12, 2024 18:46
Yet another PHP excerpt function
* @param $text
* @param int $maxLength (default 200 characters)
* @param string $ending (characters to append to the end of the excerpt)
* @return string
function excerpt($text, int $maxLength = 200, string $ending = '...'): string
// collapse whitespace
$text = preg_replace('/\s+/', ' ', $text);
artlung / update-wp-links-with-rss.php
Created March 7, 2024 07:19
artlung / RoanokeVisualization.php
Last active March 4, 2024 07:39
ArtLung Blog "Roanoke" WordPress Theme Blog Visualization Shortcode. Not packed as a plugin, would need to be modified to add to your blog. I may at some point package it up into a plugin form but feel free to extend, modify, share.
* Class RoanokeVisualization
* Creates a visualization of blog posts by year and month
* and breaks out posts, and posts with Instagram and Delicious tags
* Uses wp_get_archives to get the data
* Uses wp_cache to store the data from expensive operations
artlung / composer.json
Last active February 26, 2024 21:36
Parse Images for Colors and Populate a CSS File. Uses composer library ColorExtractor
"name": "artlung/parse-images-for-color",
"autoload": {
"psr-4": {
"Artlung\\ParseImagesForColor\\": "src/"
"authors": [
"name": "Joe Crawford",
artlung /
Created February 22, 2024 01:40
Server Side Image Map for
$defaultLink = '';
$links = [
'left' => [
'url' => '',
'x1' => 0,
'y1' => 0,
'x2' => 129,
artlung / 2004.html
Last active January 4, 2024 15:27
Header 2004 vs 2024
<table width="100%" border="0" cellpadding="0" cellspacing="0">
<tr valign="top">
<td colspan="3" bgcolor="#534741"><img src="" height="1" width="1" alt=""></td>
<tr valign="top">
<td align="left" width="33%" rowspan="2">
<img src="" width="231" height="75" alt="artlung.">
<td align="center" width="33%" rowspan="2">
<img src="" width="303" height="200" alt="in a hat to protect from the sun, making some sort of funny face.">