<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Mike / Michael Fogel &#187; tech</title>
	<atom:link href="http://www.fogel.ca/tag/tech/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.fogel.ca</link>
	<description>soapbox and search engine spam</description>
	<lastBuildDate>Wed, 31 Mar 2010 03:43:34 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Stanford Online Lectures + MEncoder + Greasemonkey</title>
		<link>http://www.fogel.ca/2010/01/25/stanford-online-lectures-mencoder-greasemonkey/</link>
		<comments>http://www.fogel.ca/2010/01/25/stanford-online-lectures-mencoder-greasemonkey/#comments</comments>
		<pubDate>Tue, 26 Jan 2010 07:35:48 +0000</pubDate>
		<dc:creator>Mike Fogel</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[greasemonkey]]></category>
		<category><![CDATA[mencoder]]></category>
		<category><![CDATA[stanford]]></category>
		<category><![CDATA[tech]]></category>

		<guid isPermaLink="false">http://blog.fogel.ca/?p=673</guid>
		<description><![CDATA[Stanford has a lot of their lectures online.  To access them, you&#8217;ve got to have&#8230; access!  That means you need to already have an SUNet ID with proper permissions.  The standard way to get those permissions is to apply to Stanford, get accepted, and start paying Stanford lots of $$$.
Stanford doesn&#8217;t want [...]]]></description>
			<content:encoded><![CDATA[<p>Stanford has a lot of their <a href="https://myvideosu.stanford.edu/oce/currentquarter.aspx">lectures</a> online.  To access them, you&#8217;ve got to have&#8230; access!  That means you need to already have an <a href="http://sunetid.stanford.edu/">SUNet ID</a> with proper permissions.  The standard way to get those permissions is to apply to Stanford, get accepted, and start paying Stanford lots of $$$.</p>
<p>Stanford doesn&#8217;t want these lectures to get out on the open internet.  So they do a few things to try to ensure that doesn&#8217;t happen.  First, part of Stanford&#8217;s terms of use is that you will not redistribute their lectures.  Note that the concepts and code I&#8217;m showing you here in this post could be used to help you illegally redistribute their lectures.  <strong>I do not condone any such illegal use.  By using the the concepts and code in this post in any way whatsoever (including just reading this post), you agree to follow Stanford&#8217;s terms of use.</strong>.  If you don&#8217;t agree to these terms, please leave now.</p>
<p>In addition to their terms of use, Stanford places a more practical barrier in the way of illegal redistribution of their lectures &#8211; they only distribute their lectures as streaming WMV and Sliverlight.  Now this sucks for me, the legal end-user, for a number of reasons.  Most importantly, this means I need a high-bandwidth connection to watch my lectures.  I can&#8217;t watch them offline.</p>
<p>Enter <a href="https://help.ubuntu.com/community/MEncoder">MEncoder</a> and <a href="https://addons.mozilla.org/en-US/firefox/addon/748">Greasemonkey</a>.</p>
<p>MEncoder is a tool to save streaming video to disk.  Greasemonkey is a Firefox browser extension that allows you to run custom javascript for any particular page displayed in the browser.</p>
<p>To save a lecture to disk for offline viewing, the basic command you want to run is:</p>
<pre>mencoder mms://the-streaming-video.wmv -ovc copy -oac copy -O filename_out.avi</pre>
<p>Now the &#8216;path-to-streaming-video.wmv&#8217; you need to use will be unique for your authenticated SUNet session with Stanford&#8217;s servers.  You can manually find this unique path by navigating with your browser to the lecture you&#8217;re interested in, viewing the source of the page, and manually scanning for the path.  Or you can install the following small and simple Greasemonkey script.</p>
<pre>
// ==UserScript==
// @name          Stanford Video MMS Path Retriever
// @copyright     2010, Mike Fogel, http://fogel.ca
// @license       This SW may not be used to violate Stanford's terms of use.
// @namespace     http://fogel.ca/greasemonkey
// @description   Adds a header containing mms path to Stanford player page.
// @include       https://myvideosu.stanford.edu/player/slplayer.aspx*
// ==/UserScript==

function get_mms_path() {
  var o = document.getElementById('WMPlayer');
  return 'mms' +  o.data.substring('http'.length);
}

function add_header(message) {
var elem = document.createElement('div');
  elem.id = 'GM_mms_path';
  elem.style.color = 'green';
  elem.innerHTML = '&lt;h2&gt;'+message+'&lt;/h2&gt;';
  document.body.insertBefore(elem, document.body.firstChild);
  return elem;
}

function set_selection(hdr) {
  var range = document.createRange();
  range.selectNodeContents(hdr.firstChild);
  selection = window.getSelection();
  selection.removeAllRanges();
  selection.addRange(range);
}

function main() {
  var mms = get_mms_path();
  var hdr = add_header(mms);
  set_selection(hdr);
}

main();
</pre>
<p>The Greasemonkey script scrapes the page, finds the &#8216;path-to-streaming-video.wmv&#8217;, adds it in large, bright green text to the top of the page, and selects it so you can just hit &#8216;cntrl-c&#8217; to copy it to your clipboard.  Then over in a terminal, you can paste that path into your MEncoder command.  Running the command will take a long time &#8211; in fact, as long as the lecture is.  This is because MEncoder simulates a regular streaming video player to the Stanford servers.  MEncoder will convert and save the streaming video according the the suffix of the output filename you specify (eg. &#8216;.avi&#8217; in my above example).</p>
]]></content:encoded>
			<wfw:commentRss>http://www.fogel.ca/2010/01/25/stanford-online-lectures-mencoder-greasemonkey/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Verizon Routing FAIL</title>
		<link>http://www.fogel.ca/2009/06/24/verizon-routing-fail/</link>
		<comments>http://www.fogel.ca/2009/06/24/verizon-routing-fail/#comments</comments>
		<pubDate>Wed, 24 Jun 2009 19:39:42 +0000</pubDate>
		<dc:creator>Mike Fogel</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[tech]]></category>
		<category><![CDATA[verizon]]></category>

		<guid isPermaLink="false">http://blog.fogel.ca/?p=561</guid>
		<description><![CDATA[I&#8217;ve got a Verizon data uplink thinger for my laptop.  This is the second day in a row they&#8217;re not able to route my packets.  Yesterday I couldn&#8217;t access a shared host on WebFaction&#8217;s network.  Today I can&#8217;t access my Slicehost VPS.

mike@110psi:~$ traceroute dev.thefirewoodguys.com
traceroute to dev.thefirewoodguys.com (67.23.12.250), 30 hops max, 60 byte [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve got a Verizon data uplink thinger for my laptop.  This is the second day in a row they&#8217;re not able to route my packets.  Yesterday I couldn&#8217;t access a shared host on <a href="http://www.webfaction.com?affiliate=projectsender">WebFaction&#8217;s</a> network.  Today I can&#8217;t access my <a href="https://manage.slicehost.com/customers/new?referrer=8f77c875bfd936b7acd5d66c3d1a08d5">Slicehost VPS</a>.</p>
<pre>
mike@110psi:~$ traceroute dev.thefirewoodguys.com
traceroute to dev.thefirewoodguys.com (67.23.12.250), 30 hops max, 60 byte packets
 1  64.sub-66-174-217.myvzw.com (66.174.217.64)  73.717 ms  74.616 ms  75.561 ms
 2  127.sub-66-174-217.myvzw.com (66.174.217.127)  85.524 ms  86.513 ms  86.485 ms
 3  138.sub-66-174-31.myvzw.com (66.174.31.138)  101.457 ms  101.434 ms  101.414 ms
 4  233.sub-66-174-217.myvzw.com (66.174.217.233)  99.385 ms  100.343 ms  75.903 ms
 5  194.sub-66-174-217.myvzw.com (66.174.217.194)  77.883 ms  77.870 ms  77.858 ms
 6  98.sub-66-174-31.myvzw.com (66.174.31.98)  77.847 ms  77.837 ms  72.877 ms
 7  169.sub-66-174-31.myvzw.com (66.174.31.169)  73.820 ms  74.790 ms  82.772 ms
 8  162.sub-66-174-31.myvzw.com (66.174.31.162)  81.781 ms  82.744 ms  83.737 ms
 9  169.sub-66-174-31.myvzw.com (66.174.31.169)  83.729 ms  83.721 ms  83.713 ms
10  162.sub-66-174-31.myvzw.com (66.174.31.162)  75.838 ms  75.791 ms  76.679 ms
11  169.sub-66-174-31.myvzw.com (66.174.31.169)  77.664 ms  78.606 ms  78.576 ms
12  162.sub-66-174-31.myvzw.com (66.174.31.162)  69.817 ms  70.718 ms  77.700 ms
13  169.sub-66-174-31.myvzw.com (66.174.31.169)  78.646 ms  78.617 ms  78.588 ms
14  162.sub-66-174-31.myvzw.com (66.174.31.162)  78.565 ms  79.526 ms  79.503 ms
15  169.sub-66-174-31.myvzw.com (66.174.31.169)  79.487 ms  66.962 ms  66.941 ms
16  162.sub-66-174-31.myvzw.com (66.174.31.162)  67.833 ms  72.801 ms  73.800 ms
17  169.sub-66-174-31.myvzw.com (66.174.31.169)  73.787 ms  79.906 ms  80.854 ms
18  162.sub-66-174-31.myvzw.com (66.174.31.162)  80.840 ms  80.828 ms  81.807 ms
19  169.sub-66-174-31.myvzw.com (66.174.31.169)  81.795 ms  81.786 ms  91.778 ms
20  162.sub-66-174-31.myvzw.com (66.174.31.162)  92.730 ms  93.720 ms  70.790 ms
21  169.sub-66-174-31.myvzw.com (66.174.31.169)  71.735 ms  72.670 ms  77.668 ms
22  162.sub-66-174-31.myvzw.com (66.174.31.162)  75.614 ms  76.604 ms  82.729 ms
23  169.sub-66-174-31.myvzw.com (66.174.31.169)  81.718 ms  82.645 ms  84.634 ms
24  162.sub-66-174-31.myvzw.com (66.174.31.162)  86.585 ms  86.555 ms  86.529 ms
25  169.sub-66-174-31.myvzw.com (66.174.31.169)  86.505 ms  86.481 ms  86.464 ms
26  162.sub-66-174-31.myvzw.com (66.174.31.162)  67.786 ms  68.690 ms  69.682 ms
27  169.sub-66-174-31.myvzw.com (66.174.31.169)  74.649 ms  75.588 ms  75.559 ms
28  162.sub-66-174-31.myvzw.com (66.174.31.162)  73.911 ms  100.955 ms  100.945 ms
29  169.sub-66-174-31.myvzw.com (66.174.31.169)  101.868 ms  104.849 ms  104.840 ms
30  162.sub-66-174-31.myvzw.com (66.174.31.162)  103.834 ms  109.823 ms  110.813 ms
</pre>
<p>The solution?  Disconnect and reconnect.  Verizon will give you a new IP, and if you&#8217;re lucky, your packets will now (by chance) get routed around their fail.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.fogel.ca/2009/06/24/verizon-routing-fail/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Django Book Dump</title>
		<link>http://www.fogel.ca/2009/06/17/django-book-dump/</link>
		<comments>http://www.fogel.ca/2009/06/17/django-book-dump/#comments</comments>
		<pubDate>Wed, 17 Jun 2009 08:04:20 +0000</pubDate>
		<dc:creator>Mike Fogel</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[django]]></category>
		<category><![CDATA[tech]]></category>

		<guid isPermaLink="false">http://blog.fogel.ca/?p=544</guid>
		<description><![CDATA[This script will make a dump of the Django Book to your local filesystem so you can read it offline.  Like say on a flight and you don&#8217;t want to pay 10 bucks for an hour of wifi.  Even though you&#8217;re stoked you finally can, if you need/want to.
This script makes all the [...]]]></description>
			<content:encoded><![CDATA[<p>This script will make a dump of the <a href="http://www.djangobook.com/en/2.0/">Django Book</a> to your local filesystem so you can read it offline.  Like say on a flight and you don&#8217;t want to pay <a href="http://wifi.virginamerica.com/">10 bucks for an hour of wifi</a>.  Even though you&#8217;re stoked you finally can, if you need/want to.</p>
<p>This script makes all the css links work so everything&#8217;s pretty.  Also, Firefox by default won&#8217;t render index.html files as directory indexes when working in the &#8216;file://&#8217; scheme, so this script rewrites internal links so that the index.html is explicit.</p>
<pre>
#!/bin/sh

# this script downloads a copy of the 2.0 django book, complete with css and
# sets it up so you can read it in-flight

WEB_RT="http://www.djangobook.com/en/2.0"
MIN_CHP=1
MAX_CHP=20

CSS1=http://new-media.djangobook.com/yui/container/assets/container.css
CSS2=http://new-media.djangobook.com/yui-ext/css/resizable.css
CSS3=http://new-media.djangobook.com/yui-ext/css/tabs.css
CSS4=http://new-media.djangobook.com/djangobook.css
CSS5=http://new-media.djangobook.com/yui/grids/grids-min.css
CSS6=http://new-media.djangobook.com/yui/reset/reset-min.css

CSS1_FILE=container.css
CSS2_FILE=resizable.css
CSS3_FILE=tabs.css
CSS4_FILE=djangobook.css
CSS5_FILE=grids-min.css
CSS6_FILE=reset-min.css

DIR_RT=django_book

echo "************ Setting up our dir structure *****************"
mkdir $DIR_RT
mkdir $DIR_RT/css
for i in `seq -f 'chapter%02.0f' $MIN_CHP $MAX_CHP`; do
  mkdir $DIR_RT/$i
done

echo "*********** Downloading all the content *****************"
wget $WEB_RT/ -P $DIR_RT
for i in $CSS1 $CSS2 $CSS3 $CSS4 $CSS5 $CSS6; do
  wget $i -P $DIR_RT/css/
done
for i in `seq -f 'chapter%02.0f' $MIN_CHP $MAX_CHP`; do
  wget $WEB_RT/$i/ -P  $DIR_RT/$i/
done

echo "************** Fixing up the css links ****************"
for i in `seq 1 6`; do
  eval "CSS_F=\"\$CSS${i}_FILE\""
  sed -i "s/href=\".*$CSS_F\"/href=\"css\/$CSS_F\"/" $DIR_RT/index.html
done

for i in `seq -f 'chapter%02.0f' $MIN_CHP $MAX_CHP`; do
  for j in `seq 1 6`; do
    eval "CSS_F=\"\$CSS${j}_FILE\""
    sed -i "s/href=\".*$CSS_F\"/href=\"..\/css\/$CSS_F\"/" $DIR_RT/$i/index.html
  done
done

echo "*************** Fixing up the page links **************"
sed -i "s/href='chapter[0-9]\{2\}\//&#038;index.html/" $DIR_RT/index.html
for i in `seq -f 'chapter%02.0f' $MIN_CHP $MAX_CHP`; do
  sed -i "s/href=\"..\"/href=\"..\/index.html\"/" $DIR_RT/$i/index.html
  sed -i "s/href='..\/chapter[0-9]\{2\}\//&#038;index.html/" $DIR_RT/$i/index.html
done
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.fogel.ca/2009/06/17/django-book-dump/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Small, readable, monospace font = ProFont</title>
		<link>http://www.fogel.ca/2009/05/26/small-readable-monospace-font-profont/</link>
		<comments>http://www.fogel.ca/2009/05/26/small-readable-monospace-font-profont/#comments</comments>
		<pubDate>Tue, 26 May 2009 20:23:27 +0000</pubDate>
		<dc:creator>Mike Fogel</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[fonts]]></category>
		<category><![CDATA[tech]]></category>

		<guid isPermaLink="false">http://blog.fogel.ca/?p=530</guid>
		<description><![CDATA[I just installed ProFont on my Debian machine, using this howto.  If you&#8217;re looking for a monospace font that maintains readability at extra small sizes, ProFont&#8217;s for you.  On my 1920&#215;1280 15.4&#8243; LCD display (147 pixels/inch), this allows me to stack up three 80-char wide terminals side by side by side, using ProFont [...]]]></description>
			<content:encoded><![CDATA[<p>I just installed <a href="http://www.tobias-jung.de/seekingprofont/">ProFont</a> on my Debian machine, using this <a href="http://www.fluidscape.co.nz/node/92">howto</a>.  If you&#8217;re looking for a monospace font that maintains readability at extra small sizes, ProFont&#8217;s for you.  On my 1920&#215;1280 15.4&#8243; LCD display (147 pixels/inch), this allows me to stack up three 80-char wide terminals side by side by side, using ProFont at 7 pixels, while maintaining readability.  Screen real estate galore!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.fogel.ca/2009/05/26/small-readable-monospace-font-profont/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>T61p/Debian/Gnome/Gsynaptics HOWTO</title>
		<link>http://www.fogel.ca/2009/04/27/t61pdebiangnomegsynaptics-howto/</link>
		<comments>http://www.fogel.ca/2009/04/27/t61pdebiangnomegsynaptics-howto/#comments</comments>
		<pubDate>Mon, 27 Apr 2009 18:46:13 +0000</pubDate>
		<dc:creator>Mike Fogel</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[debian]]></category>
		<category><![CDATA[gnome]]></category>
		<category><![CDATA[howto]]></category>
		<category><![CDATA[synaptics]]></category>
		<category><![CDATA[t61p]]></category>
		<category><![CDATA[tech]]></category>

		<guid isPermaLink="false">http://blog.fogel.ca/?p=516</guid>
		<description><![CDATA[gsynaptics gives you a nice little GUI in gnome to control the options on your synaptics touchpad, like the one my T61p came with.  It&#8217;s easy to set up on a default debian install, you just need to add a few stanazas to your xorg.conf

Here&#8217;s the edits I needed from a default install xorg.conf:

Make [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://gsynaptics.sourceforge.jp/">gsynaptics</a> gives you a nice little GUI in gnome to control the options on your synaptics touchpad, like the one my <a href="http://shop.lenovo.com/ISS_Static/merchandising/US/PDFs/T61p_Datasheet-USEN-00.pdf">T61p</a> came with.  It&#8217;s easy to set up on a default debian install, you just need to add a few stanazas to your <a href="http://www.x.org/archive/X11R6.8.0/doc/xorg.conf.5.html">xorg.conf<br />
</a></p>
<p>Here&#8217;s the edits I needed from a default install xorg.conf:</p>
<ol>
<li>Make a backup of your current xorg.conf</li>
<li>Remove the &#8220;Generic Mouse&#8221; section.  You don&#8217;t need it anymore.</li>
<li>Add a section for your touchpad like so:
<pre>
Section "InputDevice"
  Identifier  "Synaptics Touchpad"
  Driver      "synaptics"
  Option      "SendCoreEvents"  "true"
  Option      "Protocol"        "auto-dev"
  Option      "Device"          "/dev/psaux"
  Option      "SHMConfig"       "true"
EndSection
</pre>
</li>
<li>And add a line in your &#8220;ServerLayout&#8221; section referencing your new synaptics section.  I didn&#8217;t have a ServerLayout section so I had to add one, mine looks like this:
<pre>
Section "ServerLayout"
  Identifier  "Default Layout"
  Screen      "Default Screen"
  InputDevice "Generic Keyboard"
  InputDevice "Synaptics Touchpad"
EndSection
</pre>
</li>
</ol>
<p>Now save everything you&#8217;re doing and then restart X11 by hitting cntrl-alt-backspace.  If X won&#8217;t start back up, you can hit cntrl-alt-f1 and log in at a command prompt, restore your xorg.conf from the backup you made earlier, then run <code>/etc/init.d/gdm restart</code>.</p>
<p>In the event that things just aren&#8217;t working, your friend is /var/log/Xorg.0.log.  That log file contains the results of your x-server&#8217;s parsing of your xorg.conf.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.fogel.ca/2009/04/27/t61pdebiangnomegsynaptics-howto/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Vimperator and browser.startup.page=[1&#124;3]</title>
		<link>http://www.fogel.ca/2009/04/19/vimperator-and-browserstartuppage13/</link>
		<comments>http://www.fogel.ca/2009/04/19/vimperator-and-browserstartuppage13/#comments</comments>
		<pubDate>Mon, 20 Apr 2009 06:16:21 +0000</pubDate>
		<dc:creator>Mike Fogel</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[FF]]></category>
		<category><![CDATA[tech]]></category>
		<category><![CDATA[vimperator]]></category>

		<guid isPermaLink="false">http://blog.fogel.ca/?p=502</guid>
		<description><![CDATA[First, for anyone out there that&#8217;s pretty quick with vi, I&#8217;d recommend you check out the vimperator extension for FF if you haven&#8217;t already.  It speeds up my sessions quite a bit.
It turns out vimperator sets the browser option browser.startup.page=3 for you every time you fire up your browser.  You can see this [...]]]></description>
			<content:encoded><![CDATA[<p>First, for anyone out there that&#8217;s pretty quick with vi, I&#8217;d recommend you check out the <a href="http://vimperator.org/trac/wiki/Vimperator">vimperator</a> extension for FF if you haven&#8217;t already.  It speeds up my sessions quite a bit.</p>
<p>It turns out vimperator sets the browser option <a href="http://kb.mozillazine.org/Browser.startup.page">browser.startup.page</a>=3 for you every time you fire up your browser.  You can see this in your vimperator&#8217;s options.js:</p>
<pre>
// start with saved session
storePreference("browser.startup.page", 3);
</pre>
<p>This ain&#8217;t my cup of tea for a few reasons and I&#8217;m not nuts about vimperator overriding what I&#8217;ve set in my about:config without asking or telling me.  Anyway, you can override vimperator&#8217;s override.</p>
<p>In your ~/.vimperatorrc:</p>
<pre>
set! browser.startup.page=1
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.fogel.ca/2009/04/19/vimperator-and-browserstartuppage13/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Hard Drive Replacement</title>
		<link>http://www.fogel.ca/2009/04/09/hard-drive-replacement/</link>
		<comments>http://www.fogel.ca/2009/04/09/hard-drive-replacement/#comments</comments>
		<pubDate>Thu, 09 Apr 2009 18:58:58 +0000</pubDate>
		<dc:creator>Mike Fogel</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[harddrive]]></category>
		<category><![CDATA[hp]]></category>
		<category><![CDATA[ibm]]></category>
		<category><![CDATA[laptop]]></category>
		<category><![CDATA[mac]]></category>
		<category><![CDATA[tech]]></category>

		<guid isPermaLink="false">http://blog.fogel.ca/?p=487</guid>
		<description><![CDATA[I had to remove a few hard drives from a few laptops this morning to do some swapping.  Some of them went really easy, others, not so much.  For quick comparison, here&#8217;s the basic stats on the hard drive removal process for each.
Mac PowerBook G4:

Tools: #0 &#38; #1 Phillips, 1.5 mm Allen wrench
Screws: 34
Connectors: 5
4 [...]]]></description>
			<content:encoded><![CDATA[<p>I had to remove a few hard drives from a few laptops this morning to do some swapping.  Some of them went really easy, others, not so much.  For quick comparison, here&#8217;s the basic stats on the hard drive removal process for each.</p>
<p>Mac PowerBook G4:</p>
<ul>
<li>Tools: #0 &amp; #1 Phillips, 1.5 mm Allen wrench</li>
<li>Screws: 34</li>
<li>Connectors: 5</li>
<li>4 Keys</li>
<li>Battery, ram cover, keyboard, front cover, hard drive casing</li>
<li>90 min</li>
<li>High probability of inflicting cosmetic damage to laptop</li>
<li>You need a <a href="http://www.ifixit.com/Guide/Repair/PowerBook-G4-Aluminum-12-Inch-1-1-5-GHz-Hard-Drive/547/1">guide</a>, and plenty of organization and patience</li>
</ul>
<p><img src="http://farm3.static.flickr.com/2792/4384294670_6b64910db2.jpg" alt="removing apple HD 1" /></p>
<p><img src="http://farm5.static.flickr.com/4008/4383533559_12b96f1836.jpg" alt="removing apple HD 2" /></p>
<p>HP OmniBook 9000:</p>
<ul>
<li>#1 Phillips</li>
<li>3 Screws</li>
<li>5 minutes</li>
</ul>
<p><img src="http://farm5.static.flickr.com/4011/4384293908_33e4d241d4.jpg" alt="removing hp HD" /></p>
<p>IBM T61p:</p>
<ul>
<li>#1 Phillips</li>
<li>5 Screws</li>
<li>5 minutes</li>
</ul>
<p><img src="http://farm5.static.flickr.com/4044/4384292012_95f3a51614.jpg" alt="removing ibm HD" /></p>
<p>IBM wins as having the most user-friendly design, followed closely by HP.  Apple&#8230; uh, yeah right.</p>
<p>Apple&#8217;s products tend to be very user-friendly as long as you fit nicely into one of their predefined use cases&#8230; hard drive replacement apparently isn&#8217;t one of their use cases.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.fogel.ca/2009/04/09/hard-drive-replacement/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>555 555 5555 and Google Mail</title>
		<link>http://www.fogel.ca/2009/03/28/555-555-5555-and-google-mail/</link>
		<comments>http://www.fogel.ca/2009/03/28/555-555-5555-and-google-mail/#comments</comments>
		<pubDate>Sun, 29 Mar 2009 01:26:45 +0000</pubDate>
		<dc:creator>Mike Fogel</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[google]]></category>
		<category><![CDATA[tech]]></category>
		<category><![CDATA[thefirewoodguys]]></category>

		<guid isPermaLink="false">http://blog.fogel.ca/?p=480</guid>
		<description><![CDATA[I ran across a peculiarity with google mail&#8217;s spam checking today.  I&#8217;m running a bayarea firewood delivery site for a buddy of mine, and it has, among other awesome features, an order form containing a few &#8216;phone&#8217; strings.  When the order form is submitted, an email is sent out to a private email [...]]]></description>
			<content:encoded><![CDATA[<p>I ran across a peculiarity with google mail&#8217;s spam checking today.  I&#8217;m running a <a href="http://www.thefirewoodguys.com">bayarea firewood delivery site</a> for a buddy of mine, and it has, among other awesome features, an <a href="http://www.thefirewoodguys.com/contact.html">order form</a> containing a few &#8216;phone&#8217; strings.  When the order form is submitted, an email is sent out to a private email list which is ran using <a href="http://www.google.com/apps/intl/en/business/messaging.html">google site&#8217;s email app</a>.</p>
<p>I made a few changes to the email script, tested them in the dev environment, pushed the changes to production, then made one final test in the production environment&#8230; and holy snikes it doesn&#8217;t work!  I don&#8217;t get an email at my google email list when I submit the order form.  What??  It just worked 10 seconds ago on my dev site!</p>
<ol>
<li>Revert the production code.</li>
<li>Recreate problem in my dev environment.</li>
<li>Track down source of problem.</li>
</ol>
<p>Long story short, it turns out if I send an email to an email list handled by the google sites email app, and if it contains the string &#8216;555 555 5555&#8242; then it doesn&#8217;t go through.  Or at least it gets delayed by 1 hour+.  I haven&#8217;t seen any of them yet.</p>
<p>Change that &#8216;555 555 5555&#8242; ever so slightly &#8211; say to &#8216;555 555 5554&#8242; and it goes through in seconds.  Who would a thunk it.</p>
<p>I guess spam often has &#8216;555 555 5555&#8242; in it?  Moral of the story is a) to not get that phone number and b) don&#8217;t use common strings like that in your testing. (email@email.com?)  It can introduce unexpected variables.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.fogel.ca/2009/03/28/555-555-5555-and-google-mail/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Quick Hacking .otp</title>
		<link>http://www.fogel.ca/2009/03/12/quick-hacking-otp/</link>
		<comments>http://www.fogel.ca/2009/03/12/quick-hacking-otp/#comments</comments>
		<pubDate>Fri, 13 Mar 2009 03:52:38 +0000</pubDate>
		<dc:creator>Mike Fogel</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[openoffice]]></category>
		<category><![CDATA[tech]]></category>

		<guid isPermaLink="false">http://blog.fogel.ca/?p=471</guid>
		<description><![CDATA[I&#8217;ve got to do a presentation for a class tomorrow.  I&#8217;m busting out a few slides using Open Office Impress, which is working ok.  It can save as PPT so hopefully nobody on the other slide of the presentation will know it was made with that icky open source stuff.
I want it to [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve got to do a presentation for a <a href="http://www.stanford.edu/class/cs345a/">class</a> tomorrow.  I&#8217;m busting out a few slides using Open Office Impress, which is working ok.  It can save as PPT so hopefully nobody on the other slide of the presentation will know it was made with that icky open source stuff.</p>
<p>I want it to look good.  So I found a <a href="http://technology.chtsai.org/impress/xuhai.otp">good template</a>.</p>
<p>I cannot for the life of me figure out how to edit the &#8220;Your Name&#8221; and &#8220;Your Title&#8221; fields of this template using Open Office.  If you know how, please tell me.</p>
<p>But!  otp is an <a href="http://en.wikipedia.org/wiki/OpenDocument">open format</a>!  It&#8217;s just some zipped up xml.  So:</p>
<pre>
wget http://technology.chtsai.org/impress/xuhai.otp
unzip -d tmp xuhai.otp
cd tmp
grep -rl 'Your Name' ./*
vi styles.xml
 ..... do some editing here ....
zip -rm xuhai_more_better.otp ./*
mv ./xuhai_more_better.otp ../
cd ..
rmdir tmp
gnome-open xuhai_more_better.otp
</pre>
<p>Bam.  No heavy Open Office needed.  Why doesn&#8217;t everybody do <a href="http://xkcd.com/378/">their power points in vi</a>?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.fogel.ca/2009/03/12/quick-hacking-otp/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PHP (minor) Release History</title>
		<link>http://www.fogel.ca/2009/03/10/php-minor-release-history/</link>
		<comments>http://www.fogel.ca/2009/03/10/php-minor-release-history/#comments</comments>
		<pubDate>Tue, 10 Mar 2009 22:51:53 +0000</pubDate>
		<dc:creator>Mike Fogel</dc:creator>
				<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[tech]]></category>

		<guid isPermaLink="false">http://blog.fogel.ca/?p=453</guid>
		<description><![CDATA[A while back I had a few important (to me) bugs filed with PHP that had been fixed in trunk but hadn&#8217;t yet been released in an update.  I wanted to be able to predict about when PHP&#8217;s next minor version would be released &#8211; but I didn&#8217;t find that info in an easily [...]]]></description>
			<content:encoded><![CDATA[<p>A while back I had a few important (to me) bugs filed with PHP that had been fixed in trunk but hadn&#8217;t yet been released in an update.  I wanted to be able to predict about when PHP&#8217;s next minor version would be released &#8211; but I didn&#8217;t find that info in an easily human-digestible format out there.  Soooo&#8230; this script pumps out minor version release dates in a delumpishly simple format.  Yum, yum.</p>
<pre>
#!/usr/bin/php
&lt;?php

// this script pumps out version/date from php 5 changlog

$url = 'http://us3.php.net/ChangeLog-5.php';
$regex_version = '/^\&lt;h3\&gt;(.*)\&lt;\/h3\&gt;$/';
$regex_date = '/^\&lt;b\&gt;(.*)\&lt;\/b\&gt;$/';

$lines = file($url);
while(list($k, $v) = each($lines)) {
  if (preg_match($regex_version, $v, $matches)) {
    $version = $matches[1];
    list($k, $v) = each($lines);
    preg_match($regex_date, $v, $matches);
    $date = $matches[1];
    echo str_pad($date, 20) . $version . &quot;\n&quot;;
  }
}

?&gt;
</pre>
<p>As of 2009/03/10&#8230;</p>
<pre>
26-February-2009    Version 5.2.9
08-December-2008    Version 5.2.8
04-December-2008    Version 5.2.7
01-May-2008         Version 5.2.6
08-November-2007    Version 5.2.5
30-August-2007      Version 5.2.4
31-May-2007         Version 5.2.3
03-May-2007         Version 5.2.2
08-Feb-2007         Version 5.2.1
02-Nov-2006         Version 5.2.0
24-Aug-2006         Version 5.1.6
17-Aug-2006         Version 5.1.5
04-May-2006         Version 5.1.4
02-May-2006         Version 5.1.3
12-Jan-2006         Version 5.1.2
28-Nov-2005         Version 5.1.1
24-Nov-2005         Version 5.1.0
05-Sep-2005         Version 5.0.5
31-Mar-2005         Version 5.0.4
15-Dec-2004         Version 5.0.3
23-Sep-2004         Version 5.0.2
12-Aug-2004         Version 5.0.1
13-Jul-2004         Version 5.0.0
8-Jun-2004          Version 5.0.0 Release Candidate 3
25-Apr-2004         Version 5.0.0 Release Candidate 2
18-Mar-2004         Version 5.0.0 Release Candidate 1
12-Feb-2004         Version 5.0.0 Beta 4
21-Dec-2003         Version 5.0.0 Beta 3
30-Oct-2003         Version 5.0.0 Beta 2
29-Jun-2003         Version 5.0.0 Beta 1
</pre>
]]></content:encoded>
			<wfw:commentRss>http://www.fogel.ca/2009/03/10/php-minor-release-history/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
