This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php /* Template Name: Words Legacy Template */ ?> | |
<!DOCTYPE html> | |
<html prefix="og: http://ogp.me/ns#" <?php language_attributes(); ?>> | |
<head> | |
<title><?php echo wp_title('', false, 'left'); ?> : Joe Crawford (ArtLung.com)</title> | |
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> | |
<meta name="viewport" content="width=device-width, initial-scale=1" /> | |
<link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="<?php bloginfo('rss2_url'); ?>" /> | |
<link rel="alternate" type="application/atom+xml" title="Atom 0.3" href="<?php bloginfo('atom_url'); ?>" /> | |
<?php wp_head(); ?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/local/bin/perl | |
require 'ctime.pl'; | |
require 'newgetopt.pl'; | |
#require '/usr/local/lib/perl5/ctime.pl'; | |
#require '/usr/local/lib/perl5/newgetopt.pl'; | |
#require '/usr/local/lib/perl5/sys/socket.ph'; | |
# | |
# ----> parse_hotlist <---- | |
# takes a file (default /chronos/c1/jerry/.hotlist |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# where /usr/home/username/public_html contains all your wordpress installs | |
# to run for the current directory and lower: | |
# find . -name wp-config.php | xargs chmod 600 | |
find /usr/home/username/public_html -name wp-config.php | xargs chmod 600 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var tds = document.querySelectorAll('td'); | |
// Use in the console for https://en.wikipedia.org/wiki/List_of_largest_daily_changes_in_the_Dow_Jones_Industrial_Average | |
for (var i = 0; i<tds.length; i++) { | |
var td = tds[i]; | |
if (td.innerText.indexOf('2020-0') === -1) { | |
td.style.opacity = 0.3; | |
td.style.backgroundColor = td.style.backgroundColor.toString().replace(')', ',0.3)'); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* User: artlung | |
* Date: 2019-08-24 | |
* A variation of https://gist.github.com/artlung/210438 : | |
* | |
* "I have a list of URLs in 10 columns of a CSV file and I need a separate | |
* sitemap for each column. Can we modify this code accordingly?" | |
* | |
* This is a quick way to turn a simple comma-separated file |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> | |
<html> | |
<head> | |
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> | |
<style> | |
.AlignLeft { text-align: left; } | |
.AlignCenter { text-align: center; } | |
.AlignRight { text-align: right; } | |
body { font-family: sans-serif; font-size: 11pt; } | |
img.AutoScale { max-width: 100%; max-height: 100%; } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// needed as a debugging shim | |
class Blah { | |
function ip() { | |
if(!empty($_SERVER['HTTP_CLIENT_IP'])){ | |
//ip from share internet | |
$ip = $_SERVER['HTTP_CLIENT_IP']; | |
}elseif(!empty($_SERVER['HTTP_X_FORWARDED_FOR'])){ | |
//ip pass from proxy | |
$ip = $_SERVER['HTTP_X_FORWARDED_FOR']; | |
}else{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function find_tags($str) { | |
$tags = []; | |
$words = explode(" ", $str); | |
foreach ($words as $word) { | |
if (substr($word, 0, 1) === "#") { | |
$value = strtolower(str_replace([".",":","#","!","\"", "@", "(", ")"],"",$word)); | |
if (strlen($value) > 2) { | |
$tags[] = $value; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
100 CALL CLEAR | |
110 CALL CHAR(96, "FFFFFFFFFFFFFFFF") | |
120 CALL CHAR(42, "0F0F0F0F0F0F0F0F") | |
130 CALL HCHAR(12,17,42) | |
140 CALL VCHAR(14,17,96) | |
150 FOR DELAY=1 TO 500 | |
160 NEXT DELAY |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function getStars($number) { | |
$digits = floor($number); | |
$remainder = $number - $digits; | |
// http://php.net/round | |
$remainder = round($remainder, 0, PHP_ROUND_HALF_UP); | |
return str_repeat('*', $digits) . (($remainder > 0) ? '½' : ''); | |
} |