<?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>Joe Fleming dot net</title>
	<atom:link href="http://joefleming.net/feed/" rel="self" type="application/rss+xml" />
	<link>http://joefleming.net</link>
	<description>what you see is what you get</description>
	<lastBuildDate>Wed, 26 May 2010 19:25:49 +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>Atheros AR8131 and Linux</title>
		<link>http://joefleming.net/2010/05/26/atheros-ar8131-and-linux/</link>
		<comments>http://joefleming.net/2010/05/26/atheros-ar8131-and-linux/#comments</comments>
		<pubDate>Wed, 26 May 2010 19:25:49 +0000</pubDate>
		<dc:creator>Joe</dc:creator>
				<category><![CDATA[Computers & Technology]]></category>
		<category><![CDATA[Hardware]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[compile]]></category>
		<category><![CDATA[networking]]></category>
		<category><![CDATA[ubuntu]]></category>

		<guid isPermaLink="false">http://joefleming.net/?p=177</guid>
		<description><![CDATA[A while back I picked up an ECS 945GCD-M motherboard to replace my dead VIA board that was running my RAID server. The board is pretty nice, sitting there completely silent, running 64-bit Ubuntu and packing far more power than the board it was replacing. But it has one glaring problem; the network card on [...]]]></description>
			<content:encoded><![CDATA[<p>A while back I picked up an ECS 945GCD-M motherboard to replace my dead VIA board that was running my RAID server. The board is pretty nice, sitting there completely silent, running 64-bit Ubuntu and packing far more power than the board it was replacing. But it has one glaring problem; the network card on the thing didn&#8217;t work out of the box in Linux. I had been running a cheap USB network card I had laying around, but it was slow and I hated that I couldn&#8217;t get it working. So, I set out to make the onboard Atheros AR8131M chipset work.</p>
<p>Google will give you a plethora of guides for compiling the drivers (<a href="http://ubuntuforums.org/showthread.php?t=1255082">this one is probably the best</a>), but I just couldn&#8217;t get things to load. It was also never clear what version of the drivers I should be trying to run. Most tutorials made reference to 1.0.0.9, some to 1.0.0.10, but the current version (at the time of this writing) is 1.0.1.9. In the end, though, that&#8217;s the version I did manage to get working. Here&#8217;s how I did it:<br />
<span id="more-177"></span></p>
<ul>
<li>Grab the driver from the <a href="http://partner.atheros.com/Drivers.aspx">Atheros site</a></li>
<li>Locate the file on your computer, then make a new directory (name it anything, <em>AR8131</em> will work) and move that file there
</li>
<li>Decompress the file</li>
<li>Enter the resulting <em>src</em> directory</li>
</ul>
<p>Once you in there, it&#8217;s time to start that terminal magic! One note; if you&#8217;ve already added another network card to your machine, the Atheros card may be eth1, not eth0. This was the case for me, and I&#8217;ll treat all the instructions here as though that&#8217;s the case for you too. If it&#8217;s not, just change eth1 to eth0.<br />
<code>make &#038;&#038; sudo make install<br />
sudo modprobe atl1e<br />
sudo ifconfig eth1 up<br />
sudo dhclient eth1<br />
</code></p>
<p>At this point, the machine will try to assign an IP address for the card. This may or may not work; for me, it did not. To get mine working, I simply restarted the networking init script. Before that though, let&#8217;s add the following to <em>/etc/network/interfaces</em><br />
<code># The secondary network interface<br />
auto eth1<br />
iface eth1 inet dhcp</code></p>
<p>And lastly, restart the network on the machine (you CAN reboot, but there&#8217;s no need).<br />
<code>sudo /etc/init.d/networking restart</code></p>
<p>At this point, you should have your network card up and running with an IP address assigned by your DHCP server or router. If not, keep hunting I guess, but you should at least be very close!</p>
]]></content:encoded>
			<wfw:commentRss>http://joefleming.net/2010/05/26/atheros-ar8131-and-linux/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Tweaking Gnome for Low-Resolution Displays</title>
		<link>http://joefleming.net/2010/05/13/tweaking-gnome-for-low-resolution-displays/</link>
		<comments>http://joefleming.net/2010/05/13/tweaking-gnome-for-low-resolution-displays/#comments</comments>
		<pubDate>Thu, 13 May 2010 17:23:48 +0000</pubDate>
		<dc:creator>Joe</dc:creator>
				<category><![CDATA[Computers & Technology]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Open Source]]></category>
		<category><![CDATA[Usability]]></category>
		<category><![CDATA[display]]></category>
		<category><![CDATA[gnome]]></category>
		<category><![CDATA[ubuntu]]></category>

		<guid isPermaLink="false">http://joefleming.net/?p=169</guid>
		<description><![CDATA[I&#8217;m a fan of Ubuntu, and I&#8217;m kind of lazy about setting up my desktop, which means I&#8217;m using Gnome as my window manager. Over the years I&#8217;ve grown to like it&#8230; it&#8217;s not perfect, but it&#8217;s livable and works pretty well. One of the problems I&#8217;ve always had with it, though, is all of [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m a fan of Ubuntu, and I&#8217;m kind of lazy about setting up my desktop, which means I&#8217;m using Gnome as my window manager. Over the years I&#8217;ve grown to like it&#8230; it&#8217;s not perfect, but it&#8217;s livable and works pretty well. One of the problems I&#8217;ve always had with it, though, is all of the window elements in it are huge. This makes it look kind of childish and eats up a lot of screen real estate on the 1280&#215;800 display on my desktop. I couldn&#8217;t even imaging running it on a lower resolution!</p>
<p>I was discussing this with my friend <a href="http://jasonsidabras.com/">Jason</a> and he recommended playing with the font sizes. Sure enough, that did the trick! It seems that the reason everything is so big is that the default font sizes are 10pt. I shrank them down and MAN does it look nice now!</p>
<p>You can edit these values one ways; via gconf-editor or via gconftool-2 on the command line. I won&#8217;t post the gconf-editor direction since, if you know your way around it, you can extrapolate the parts you want to edit via the gconftool-2 commands. The following settings worked extremely well for me, but you can adjust the font faces and sizes as you see fit.</p>
<p><code>gconftool-2 --type string --set /apps/metacity/general/titlebar_font "Sans Bold 8"<br />
gconftool-2 --type string --set /desktop/gnome/interface/font_name "Sans 9"<br />
gconftool-2 --type string --set /desktop/gnome/interface/monospace_font_name "Monospace 9"</code></p>
<p>This will adjust the title bar, all normal window text and all monospace text, respectively. Again, these numbers looked the best to me, but you can make them even smaller (or bigger) to fit your needs. I did these adjustments on my 1680&#215;1050 display as well, and it looks amazing. Then again, I love small text!<br />
<span id="more-169"></span><br />
Another way to free up screen space is to auto-hide the panel(s) you have. Now, I know this is cumbersome with the default settings because it&#8217;s slow to respond and expand, but you can tweak that stuff too. Here&#8217;s what I have set:</p>
<p><code>gconftool-2 --type boolean --set /apps/panel/toplevels/top_panel_screen0/auto_hide 1<br />
gconftool-2 --type boolean --set /apps/panel/toplevels/top_panel_screen0/enable_animations 1<br />
gconftool-2 --type string --set /apps/panel/toplevels/top_panel_screen0/animation_speed fast<br />
gconftool-2 --type string --set /apps/panel/toplevels/top_panel_screen0/hide_delay 500<br />
gconftool-2 --type string --set /apps/panel/toplevels/top_panel_screen0/unhide_delay 100</code></p>
<p>Now, it opens much faster, animates much faster and goes away much faster. the hide_delay is fast enough that if I&#8217;m sloppy with the pointer, it still doesn&#8217;t disappear when I don&#8217;t want it to. Still annoying? play around with the hide and unhide delays until it works for you. Still too slow to pop in? Set enable_animations to 0 and it&#8217;ll come on the screen instantly.</p>
<p>As an added piece of advice, if your panel is over-crowded with junk, you can add another panel (or 2 or 3&#8230;) to separate out tasks. For example, I have a small, hidden, non-expanding panel I keep in the bottom left of the screen on which I have my timer-applet and my hamster-applet. Additionally, if you have something on your panel that you always want to see on your screen, add it to another panel that you don&#8217;t hide. </p>
]]></content:encoded>
			<wfw:commentRss>http://joefleming.net/2010/05/13/tweaking-gnome-for-low-resolution-displays/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Serving Files in Internet Explorer over HTTPS</title>
		<link>http://joefleming.net/2010/05/11/serving-files-in-internet-explorer-over-https/</link>
		<comments>http://joefleming.net/2010/05/11/serving-files-in-internet-explorer-over-https/#comments</comments>
		<pubDate>Tue, 11 May 2010 21:34:13 +0000</pubDate>
		<dc:creator>Joe</dc:creator>
				<category><![CDATA[Computers & Technology]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[Web Development]]></category>
		<category><![CDATA[https]]></category>

		<guid isPermaLink="false">http://joefleming.net/?p=163</guid>
		<description><![CDATA[I recently came across a problem where serving a file to Internet Explorer would result in the following error message.

This affected IE6, IE7 and IE8 in my testing. The way I was serving the file was through PHP via readfile. Before sending the contents of the file, I was, of course, setting some header parameters [...]]]></description>
			<content:encoded><![CDATA[<p>I recently came across a problem where serving a file to Internet Explorer would result in the following error message.<br />
<a href="http://joefleming.net/wp-content/uploads/2010/05/Untitled.jpg"><img src="http://joefleming.net/wp-content/uploads/2010/05/Untitled-300x200.jpg" alt="" title="IE_Error" width="300" height="200" class="alignnone size-medium wp-image-164" /></a></p>
<p>This affected IE6, IE7 and IE8 in my testing. The way I was serving the file was through PHP via <a href="http://us2.php.net/manual/en/function.readfile.php">readfile</a>. Before sending the contents of the file, I was, of course, setting some header parameters so that the browser would handle the file and the user wouldn&#8217;t just see some binary garbage on their screen. In my case, I was serving a PDF file that was being generated server-side and sent to the client. The basic header parameters are as follows:</p>
<p><code>// We'll be outputting a PDF<br />
 header('Content-type: application/pdf');<br />
 // It will be called your_file.pdf<br />
 header('Content-Disposition: attachment; filename="your_file.pdf"');<br />
 // declare Files Size here (for the sake pf peoples sanity, please add this<br />
 header('Content-Length: '.filesize($filename));</code></p>
<p>This works just fine in most situations, but once you introduce a secure connection, IE fails with the above error. Of course, like most IE problems, this doesn&#8217;t happen in any other browser. Ugh.<br />
<span id="more-163"></span><br />
Luckily, I noticed some additional parameters in the first example on the readfile page, namely the &#8216;Pragma&#8217; parameter. Reading some comments on the header function, I stumbled upon <a href="http://www.php.net/manual/en/function.header.php#88038">this one</a>. It basically, says that once you add HTTPS, you need to also tell IE how to handle caching the file. So now, my headers look like this:</p>
<p><code>// Force clear cache<br />
header('Pragma: public'); // Fix for IE<br />
header("Expires: 0");  //always expire<br />
header('Cache-Control: must-revalidate, post-check=0, pre-check=0');<br />
// We'll be outputting a PDF<br />
header('Content-type: application/pdf');<br />
// It will be called your_file.pdf<br />
header('Content-Disposition: attachment; filename="your_file.pdf"');<br />
// declare Files Size here (for the sake pf peoples sanity, please add this<br />
header('Content-Length: '.filesize($filename));</code></p>
<p>Directly following these header calls is the readfile call and a call to exit to stop the script from executing anything else and alert the browser that the entire file has been delivered. </p>
<p>It seems like the Pragma parameter controls how browsers handle caching, and adding the other cache parameters to the header are just added enforcement. Now, IE works exactly as expected and I&#8217;ve got happy clients once again!</p>
]]></content:encoded>
			<wfw:commentRss>http://joefleming.net/2010/05/11/serving-files-in-internet-explorer-over-https/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Samsung X360 Backlight Control with Ubuntu</title>
		<link>http://joefleming.net/2010/03/30/samsung-x360-backlight-control-with-ubuntu/</link>
		<comments>http://joefleming.net/2010/03/30/samsung-x360-backlight-control-with-ubuntu/#comments</comments>
		<pubDate>Tue, 30 Mar 2010 18:06:19 +0000</pubDate>
		<dc:creator>Joe</dc:creator>
				<category><![CDATA[Computers & Technology]]></category>
		<category><![CDATA[Hardware]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Open Source]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[karmic]]></category>
		<category><![CDATA[karmic koala]]></category>
		<category><![CDATA[samsung x360]]></category>
		<category><![CDATA[ubuntu]]></category>

		<guid isPermaLink="false">http://joefleming.net/?p=155</guid>
		<description><![CDATA[I recently send my Samsung X360 laptop to the shop. The bearing on the fan had gone bad so I sent it in for warranty replacement. Before I sent it, I thought I would wipe out all my data since a lot of it was work-related and I didn&#8217;t need that information getting out, plus [...]]]></description>
			<content:encoded><![CDATA[<p>I recently send my Samsung X360 laptop to the shop. The bearing on the fan had gone bad so I sent it in for warranty replacement. Before I sent it, I thought I would wipe out all my data since a lot of it was work-related and I didn&#8217;t need that information getting out, plus I didn&#8217;t want to confuse the poor tech with Linux. </p>
<p>When I got it back, I immediately installed Ubuntu&#8217;s most current version, 9.10 (Karmic Koala). I was really impressed with it; even more-so than with 9.04 in fact. But I ran in to a problem when I was setting it all up; I couldn&#8217;t get the backlight adjustment to work.<br />
<span id="more-155"></span><br />
I resorted to the original <a href="http://ubuntuforums.org/showthread.php?t=1031764">Ubuntu Forums article</a> on it but I quickly found that it no longer worked. LVDS and VGA had been replaced with LVDA1 and VGA1, and changing the command still didn&#8217;t work; it complained about something which I no longer remember. But, that error (as well as replies to that thread) lead me to <a href="https://bugs.launchpad.net/ubuntu/+source/xserver-xorg-video-intel/+bug/397617/comments/30">this Launchpad comment</a> about disabling KMS.</p>
<p>Seems KMS is enabled by default for a certain chipset, specifically the Intel i915 chipset. My next questions, of course, were &#8220;what is KMS&#8221; and &#8220;how do I disable it&#8221;? Looking around, I found out that KMS, or Kernel Modesetting, could be disabled <a href="http://www.ubuntu.com/getubuntu/releasenotes/910#No%20Xv%20support%20for%20Intel%2082852/855GM%20video%20chips%20with%20KMS">like so</a>:</p>
<p><code>Edit: /etc/default/grub<br />
Change: GRUB_CMDLINE_LINUX=""<br />
To: GRUB_CMDLINE_LINUX="nomodeset"</code></p>
<p>Then run</p>
<p><code>sudo update-grub</code></p>
<p>Now, reboot and KMS will be disabled. We can now refer back to the original post <a href="http://ubuntuforums.org/showthread.php?t=1031764">here</a>, adding the following to the startup applications (or just running it from the command line each time, you&#8217;re call I guess).</p>
<p><code>xrandr --output LVDS --set BACKLIGHT 102 --set BACKLIGHT_CONTROL legacy --output VGA --auto</code></p>
<p>This still won&#8217;t make the brightness buttons on the keyboard work, but it WILL make xbacklight work. As the article points out, you can then set hotkeys for xbacklight commands.</p>
<p>So what do you lose by disabling KMS? Well, according to <a href="http://fedoraproject.org/wiki/Features/KernelModesetting#Summary">this article</a>, KMS offloads the graphics initialization from X to the kernel, which has some benefits. But, the fact remains that it doesn&#8217;t work on a lot of machines (the Samsung X360, The MacBook and possible MacBook Pro, MSI&#8217;s U90, U100, and U120 netbooks and the Asus EeePC, to name a handful), so for users with this hardware, you don&#8217;t lose anything ;). I&#8217;ve read about some people having success with KMS in newer kernels, but it didn&#8217;t work for me so I&#8217;m not going to bother posting it. I&#8217;m hopeful that this will be fixed when 10.04 (Lucid Lynx) is released, but I haven&#8217;t yet tried the beta release to see.</p>
]]></content:encoded>
			<wfw:commentRss>http://joefleming.net/2010/03/30/samsung-x360-backlight-control-with-ubuntu/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Living with PulseAudio via PulseAudio Device Chooser</title>
		<link>http://joefleming.net/2010/01/06/living-with-pulseaudio-via-pulseaudio-device-chooser/</link>
		<comments>http://joefleming.net/2010/01/06/living-with-pulseaudio-via-pulseaudio-device-chooser/#comments</comments>
		<pubDate>Wed, 06 Jan 2010 15:30:25 +0000</pubDate>
		<dc:creator>Joe</dc:creator>
				<category><![CDATA[Computers & Technology]]></category>
		<category><![CDATA[Hardware]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Open Source]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[Usability]]></category>
		<category><![CDATA[pulseaudio]]></category>
		<category><![CDATA[skype]]></category>
		<category><![CDATA[ubuntu]]></category>

		<guid isPermaLink="false">http://joefleming.net/?p=151</guid>
		<description><![CDATA[Telecommuting is a pretty sweet gig with a good number of benefits. To name a few, while I&#8217;m working I can:

Toss some laundry in the machine
Start my lunch and work while it cooks
Sign for packages when they are delivered

And that&#8217;s just the tip of the iceberg. However, to make telecommuting possible, there are some technologies [...]]]></description>
			<content:encoded><![CDATA[<p>Telecommuting is a pretty sweet gig with a good number of benefits. To name a few, while I&#8217;m working I can:</p>
<ul>
<li>Toss some laundry in the machine</li>
<li>Start my lunch and work while it cooks</li>
<li>Sign for packages when they are delivered</li>
</ul>
<p>And that&#8217;s just the tip of the iceberg. However, to make telecommuting possible, there are some technologies I simply MST have working. VPN is a big one, so I can get at the computers back in the office. SSH and FTP access is important to manage servers and files. And of course, I need to communicate with people; for that, we use AIM and Skype. Up until recently, it&#8217;s been enough for me to use my Nokia N800 to make my calls back to the office. It&#8217;s no good for chatting with video though, so I needed to set it up on my desktop with my camera and, preferably, my headset.</p>
<p>Simple enough task really; both my Logitech webcam and Plantronics headset work out of the box with Ubuntu (at least in 9.04) with nearly zero configuration required. I just plug them in, tweak Skype quickly and I&#8217;m up and running. However, with the addition of PulseAudio in the more recent version of Ubuntu, this became a little trickier.<br />
<span id="more-151"></span><br />
You see, in the new version of Skype, the ONLY option I have for ANY audio, input or output, is simpley PulseAudio. No control for which device to use for different tasks. Enter <a href="http://0pointer.de/lennart/projects/padevchooser/">padevchooser</a>, short for <strong>PulseAudio Device Chooser</strong>.</p>
<p><img src="http://i.imgur.com/nZASMl.png" alt="padevchooser in action" /></p>
<p>It&#8217;s a pretty sweet application, and you should have no problem installing it since it&#8217;s in the repository (note: I&#8217;ve <a href="https://help.ubuntu.com/community/Medibuntu#Adding%20the%20Repositories">added the Medibunutu repo</a>, and it&#8217;s possible it came from there). Once installed, you simply run it, from the command line, the run dialog, gnome-do or whatever method you choose, and you&#8217;ll get an icon in the notification area. Click on that, choose Volume Control, and you&#8217;re off and running. There are tabs for Playback, Recording, Output Devices, and Input Devices. Any current audio stream will show up in the list in the appropriate tab and you can move them around to different devices. </p>
<p>The easiest way to configure Skype is to place a test call. As soon as you start that call it will show up in the list. Move the &#8220;Skype: Output&#8221; stream to your headset in the Playback tab, do the same for &#8220;Skype: Input&#8221; in the Recording tab and you&#8217;re off and running. All Skype audio is now sent to your headset for easy chatting. I still haven&#8217;t figured out how to make it ring through the speakers and still use the headset for chatting, but this is good enough for now. Padevchooser made living with PulseAudio that much better!</p>
]]></content:encoded>
			<wfw:commentRss>http://joefleming.net/2010/01/06/living-with-pulseaudio-via-pulseaudio-device-chooser/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Asynchronous PHP</title>
		<link>http://joefleming.net/2009/10/16/asynchronous-php/</link>
		<comments>http://joefleming.net/2009/10/16/asynchronous-php/#comments</comments>
		<pubDate>Fri, 16 Oct 2009 18:46:53 +0000</pubDate>
		<dc:creator>Joe</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[Web Development]]></category>

		<guid isPermaLink="false">http://joefleming.net/?p=144</guid>
		<description><![CDATA[I needed to &#8220;asynchronous PHP&#8221; recently and it took me a little while to find the solution. What my script basically does is generate a PDF file for the user to download based on some parameters they have chosen. The problem was, the PDF generate take a while and during that time I needed to [...]]]></description>
			<content:encoded><![CDATA[<p>I needed to &#8220;asynchronous PHP&#8221; recently and it took me a little while to find the solution. What my script basically does is generate a PDF file for the user to download based on some parameters they have chosen. The problem was, the PDF generate take a while and during that time I needed to show the user a screen explaining that the file was being generated, which would also show the download link once the generation was complete. My setup is as follows:</p>
<p><strong>generate.php</strong></p>
<blockquote><p>This script is where the user is sent when they click &#8220;download&#8221; on the parameter choice page. This is where the asynchronous magic has to happen. From here, the user is immediately sent to <em>download.php</em>.</p></blockquote>
<p><strong>download.php</strong></p>
<blockquote><p>This script gives the user either a &#8220;please wait&#8221; message of a &#8220;click here to download&#8221; message, depending on where the target PDF has been generated yet.
</p></blockquote>
<p>My problem was, even though was added the header redirect code (shown below) to <em>generate.php</em>, the browser would still wait for the PDF to be generated before sending the user to <em>download.php</em>. In other words, it was only synchronous PHP, which didn&#8217;t help me at all.</p>
<p><code>header("Location: download.php");</code></p>
<p>Thanks to <a href="http://www.php.net/manual/en/features.connection-handling.php#89177" rel="ext">this comment</a> on php.net, I was able to make it work! Basically, you need to tell the browser that you are done sending it data, even though the PHP script will keep executing. Code below:</p>
<p><code>//redirects the browser to the new url, but continues processing in the background<br />
        function redirect_and_continue($sURL) {<br />
                header( "Location: ".$sURL );<br />
                ob_end_clean();<br />
                header("Connection: close");<br />
                ignore_user_abort();<br />
                ob_start();<br />
                header("Content-Length: 0");<br />
                ob_end_flush();<br />
                flush();<br />
                session_write_close();<br />
        }</code></p>
<p>So, the user is sent to <em>generate.php</em>, which immediately calls <em>redirect_and_continue(&#8216;download.php&#8217;)</em>, redirecting the user to <em>download.php</em> while still continuing to execute <em>generate.php</em> (and make the PDF file). Once the user is at <em>download.php</em>, the script checks for the existence of the generated PDF file (as indicated by the filename sent through the session) and uses a <a href="http://en.wikipedia.org/wiki/Meta_refresh" rel="ext">meta refresh tag</a> in the HTML to keep reloading <em>download.php</em>. Once the PDF file exists, it provides the user with a link to the PDF file for download.</p>
]]></content:encoded>
			<wfw:commentRss>http://joefleming.net/2009/10/16/asynchronous-php/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PPTP VPN Routing in Ubuntu using Network Manager</title>
		<link>http://joefleming.net/2009/10/01/pptp-vpn-routing-in-ubuntu-using-network-manager/</link>
		<comments>http://joefleming.net/2009/10/01/pptp-vpn-routing-in-ubuntu-using-network-manager/#comments</comments>
		<pubDate>Thu, 01 Oct 2009 17:19:17 +0000</pubDate>
		<dc:creator>Joe</dc:creator>
				<category><![CDATA[Site News]]></category>

		<guid isPermaLink="false">http://joefleming.net/?p=128</guid>
		<description><![CDATA[Back when I was still on Ubuntu 8.10 (Intrepid), I had near endless problems with PPTP VPN access using the network manager. I wasn&#8217;t alone, and I guess I was pretty fortunate that it worked at all. My problem with it was that routes never worked correctly so ALL of my traffic was routed through [...]]]></description>
			<content:encoded><![CDATA[<p>Back when I was still on Ubuntu 8.10 (Intrepid), I had near endless problems with PPTP VPN access using the network manager. I wasn&#8217;t alone, and I guess I was pretty fortunate that it worked at all. My problem with it was that routes never worked correctly so ALL of my traffic was routed through the VPN. To be honest, they DID work, but the connection ALWAYS dropped off after a minute, sometimes less, so it was hardly usable. This was exceptionally annoying since everything worked just fine in 8.04 (Hardy)!</p>
<p>Thankfully in 9.04 (Jaunty), things seem to be working again. In fact, as I type this, my traffic is being sent from my local connection, even though I&#8217;m connected to the VPN at work. Since this still seems to be a big problem for many people, I thought I would post what worked for me.<span id="more-128"></span></p>
<p>First things first, in order to configure PPTP using network-manager, you&#8217;ll need to install the PPTP plugin for it.</p>
<p><code>$ sudo apt-get install network-manager-pptp</code></p>
<p>After installing it, you will need to at least log off to restart network-manager. For me, I had to reboot. Before I did, I kept getting an error about a lack of secrets, which basically means that it can&#8217;t connect to the password manager. Rebooting fixed that.</p>
<p>Next comes the configuration. You will need to know the IP address of the VPN server you wish to connect to, as well as your username and password. For me, I also needed to add routes for the internal network, the network that the VPN was on (we have the VPN on its own subnet at work) and the external network that your work has assigned to it. Without those, the connection would never route properly.</p>
<p>If you&#8217;re reading this and you&#8217;ve come this far, I assume you already know how to get to the configuration, so we&#8217;ll just skip to some screenshots to help you along. That last step may be optional, but it was a requirement for my configuration to work. YMMV.</p>

<a href='http://joefleming.net/2009/10/01/pptp-vpn-routing-in-ubuntu-using-network-manager/screenshot-editing-vpn-connection-1/' title='Screenshot-Editing VPN connection 1'><img width="150" height="150" src="http://joefleming.net/wp-content/uploads/2009/10/Screenshot-Editing-VPN-connection-1-150x150.png" class="attachment-thumbnail" alt="" title="Screenshot-Editing VPN connection 1" /></a>
<a href='http://joefleming.net/2009/10/01/pptp-vpn-routing-in-ubuntu-using-network-manager/screenshot-nm-connection-editor/' title='Screenshot-nm-connection-editor'><img width="150" height="150" src="http://joefleming.net/wp-content/uploads/2009/10/Screenshot-nm-connection-editor-150x150.png" class="attachment-thumbnail" alt="" title="Screenshot-nm-connection-editor" /></a>
<a href='http://joefleming.net/2009/10/01/pptp-vpn-routing-in-ubuntu-using-network-manager/screenshot-editing-vpn-connection-1-1/' title='Screenshot-Editing VPN connection 1-1'><img width="150" height="150" src="http://joefleming.net/wp-content/uploads/2009/10/Screenshot-Editing-VPN-connection-1-1-150x150.png" class="attachment-thumbnail" alt="" title="Screenshot-Editing VPN connection 1-1" /></a>
<a href='http://joefleming.net/2009/10/01/pptp-vpn-routing-in-ubuntu-using-network-manager/screenshot-editing-ipv4-routes-for-vpn-connection-1/' title='Screenshot-Editing IPv4 routes for VPN connection 1'><img width="150" height="150" src="http://joefleming.net/wp-content/uploads/2009/10/Screenshot-Editing-IPv4-routes-for-VPN-connection-1-150x150.png" class="attachment-thumbnail" alt="" title="Screenshot-Editing IPv4 routes for VPN connection 1" /></a>

<p>Now, select the VPN connection and check out the routes.</p>
<p><code>$ route</code></p>
<p>If all went well, you should see some new routes going to the VPN network and be able to connect to the network resources. Something like this&#8230;</p>
<pre>Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
10.242.1.0      *               255.255.255.255 UH    0      0        0 ppp0
some.domain     192.168.1.1     255.255.255.255 UGH   0      0        0 eth0
some.domain     192.168.1.1     255.255.255.255 UGH   0      0        0 eth0
192.168.1.0     *               255.255.255.0   U     1      0        0 eth0
10.242.1.0      *               255.255.255.0   U     24     0        0 ppp0
10.5.1.0        *               255.255.255.0   U     24     0        0 ppp0
default         192.168.1.1     0.0.0.0         UG    0      0        0 eth0</pre>
<p>In my example, 10.242.1.0 is the VPN network, 10.5.1.0 is the internal network at work and some.domain is the reverse lookup of their IP address. Of course, 192.168.1.1 is the gateway for my local network. Look at all those beautiful ppp0 connections; working like a charm!</p>
<p>If it doesn&#8217;t work, try logging off and possibly rebooting again. If it STILL doesn&#8217;t work&#8230;. well, I&#8217;m out of ideas. There&#8217;s always Google and the <a rel="ext" href="http://ubuntuforums.org/">Ubuntu forums</a>. Good luck!</p>
]]></content:encoded>
			<wfw:commentRss>http://joefleming.net/2009/10/01/pptp-vpn-routing-in-ubuntu-using-network-manager/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Go Vote for My Will Code For Green Project</title>
		<link>http://joefleming.net/2009/07/29/go-vote-for-my-will-code-for-green-project/</link>
		<comments>http://joefleming.net/2009/07/29/go-vote-for-my-will-code-for-green-project/#comments</comments>
		<pubDate>Thu, 30 Jul 2009 02:48:57 +0000</pubDate>
		<dc:creator>Joe</dc:creator>
				<category><![CDATA[Site News]]></category>

		<guid isPermaLink="false">http://joefleming.net/?p=118</guid>
		<description><![CDATA[So, I entered the Will Code for Green contest last week at Jason&#8217;s recommendation. It was pretty clear that if we could come up with some ideas, we stood a real chance of winning the contest.
That&#8217;s where you, my trusty reader, come in. 20% of the scoring for the projects is based on the voting [...]]]></description>
			<content:encoded><![CDATA[<p>So, I entered the <a href="http://willcodeforgreen.gnomedex.com/" rel="_ext">Will Code for Green</a> contest last week at Jason&#8217;s recommendation. It was pretty clear that if we could come up with some ideas, we stood a real chance of winning the contest.</p>
<p>That&#8217;s where you, my trusty reader, come in. 20% of the scoring for the projects is based on the voting public&#8230; that&#8217;s you! <strong>So, go vote for my project, &#8220;<a href="http://greenrhino.joefleming.net" rel="ext">Green Rhino</a>,&#8221;</strong> by following these steps:</p>
<ol>
<li>Visit <a href="http://willcodeforgreen.gnomedex.com" rel="_ext">http://willcodeforgreen.gnomedex.com</a></li>
<li>Provide your email address and click &#8220;Submit&#8221;</li>
<li>On the resulting page, fill out your information (name, email,<br />
birthday, address) and the numbers and letters you see at the bottom</li>
<li>Once you successfully register, click &#8220;Go To Gallery&#8221; on the resulting page</li>
<li>Look for the &#8220;Green Rhino&#8230;&#8221; box. If you don&#8217;t see it, click the<br />
right arrow at the bottom to go to the next page. Continue browsing<br />
the pages until you find it, then click on it.</li>
<li>You will see a new dialog window explaining what Green Rhino is.<br />
Click on the URL to see it in action if you like. More importantly, at<br />
the top of the new box, click &#8220;Vote for This Entry&#8221;</li>
<li>You will be asked to confirm that you want to vote for the entry.<br />
Click &#8220;Vote for This Entry&#8221; again</li>
</ol>
<p>While you are there, you should <strong>consider voting for Jason&#8217;s project &#8220;<a href="http://eeko.jasonsidabras.com/" rel="ext">Eeko</a>&#8221; too</strong>. It is, after all, my idea, he just ran with it. If you do take the time to vote, hit me up in the comments or on twitter and let me know what you thought. Thanks!</p>
]]></content:encoded>
			<wfw:commentRss>http://joefleming.net/2009/07/29/go-vote-for-my-will-code-for-green-project/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Ubuntu 64-bit and Adobe Air</title>
		<link>http://joefleming.net/2009/06/14/ubuntu-64-bit-and-adobe-air/</link>
		<comments>http://joefleming.net/2009/06/14/ubuntu-64-bit-and-adobe-air/#comments</comments>
		<pubDate>Sun, 14 Jun 2009 23:28:50 +0000</pubDate>
		<dc:creator>Joe</dc:creator>
				<category><![CDATA[Site News]]></category>

		<guid isPermaLink="false">http://joefleming.net/?p=115</guid>
		<description><![CDATA[UPDATE 2009-10-01: I&#8217;ve just gotten Air running on my Ubuntu 9.04 (Jaunty) install. Apparently Adobe updated their installation instructions to include all the required steps now. Good for them! So, this post isn&#8217;t really useful anymore, but I&#8217;ll keep it around anyway, just in case.
There I was, running 64-bit Ubunutu and trying to get Adobe [...]]]></description>
			<content:encoded><![CDATA[<p><strong>UPDATE 2009-10-01</strong>: I&#8217;ve just gotten Air running on my Ubuntu 9.04 (Jaunty) install. Apparently Adobe updated their <a href="http://kb2.adobe.com/cps/408/kb408084.html" rel="ext">installation instructions</a> to include all the required steps now. Good for them! So, this post isn&#8217;t really useful anymore, but I&#8217;ll keep it around anyway, just in case.</p>
<p>There I was, running 64-bit Ubunutu and trying to get Adobe AIR to install. The problem is, AIR is written for 32-bit systems, so it needs some extra help installing on 64-bit Ubuntu. I managed to get it running, with a little help from <a href="http://kb2.adobe.com/cps/408/kb408084.html" rel="ext">Adobe&#8217;s site</a> and grabbing getlibs <a href="http://frozenfox.freehostia.com/cappy/" rel="ext">here</a> (their link was broken), everything looked good. That was, until I tried to install an AIR application.<br />
<span id="more-115"></span><br />
Specifically, I was trying to get <a href="http://tweetdeck.com" rel="ext">TweetDeck</a> running. The application would launch, but none of the buttons would do anything. I also tried running <a href="http://www.alertthingy.com/" rel="ext">AlertyThingy</a>, which would open and allow me to start using it, but wouldn&#8217;t actually let me add any channels. I was pretty frustrated.</p>
<p>Then I got the idea to run it from the terminal and see if the application was spitting out any errors. It was! </p>
<p><code>$ /opt/TweetDeck/bin/TweetDeck<br />
libgnome-keyring.so: cannot open shared object file: No such file or directory"</code></p>
<p>OK, so apparently I needed to install the 32-bit version of the libgnome-keyring libs. Of course, I wasn&#8217;t sure how to do this; enter Google. Apparently I wasn&#8217;t the only one trying to get Tweetdeck running on a 64-bit Ubuntu system. I found the instructions on <a href="http://beegod.org/tweetdeck-on-hardy-heron-64bit" rel="ext">this blog</a>, down near the bottom.</p>
<pre>As I already have GetLibs installed I thought this should be fairly easy to fix by grabbing the missing 32bit libs

sudo getlibs -l libgnome-keyring.so

Still no luck - TweetDeck seems to be looking for libgnome-keyring.so.0

Ok then:-

sudo getlibs -l libgnome-keyring.so.0

still no work so I look in the lib32 folder and see that libgnome-keyring.so.0 is a broken simlink linking to the non-existant libgnome-keyring.so.0.1.1 so I try

sudo getlibs -l libgnome-keyring.so.0.1.1

and hey presto simlink is fixed. On running my shell script to start the SDK TweetDeck workaround it pops up asking for Twitter logon details and in I go, perfect.</pre>
<p>Exactly the way it worked for me as well. So, now I&#8217;m using TweetDeck, and I have to say, the application is pretty awesome!  And of course, if you&#8217;re on Twitter, <a href="http://twitter.com/w33ble" rel="ext">hit me up</a> some time ;).</p>
]]></content:encoded>
			<wfw:commentRss>http://joefleming.net/2009/06/14/ubuntu-64-bit-and-adobe-air/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Ubuntu 64-bit, Firefox and Flash</title>
		<link>http://joefleming.net/2009/04/23/ubuntu-64-bit-firefox-and-flash/</link>
		<comments>http://joefleming.net/2009/04/23/ubuntu-64-bit-firefox-and-flash/#comments</comments>
		<pubDate>Thu, 23 Apr 2009 21:17:23 +0000</pubDate>
		<dc:creator>Joe</dc:creator>
				<category><![CDATA[Computers & Technology]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Software]]></category>

		<guid isPermaLink="false">http://joefleming.net/?p=108</guid>
		<description><![CDATA[OK, so you have this sweet new computer (much like myself) running 64-bit Ubuntu like a champ. Except for one thing; Flash elements on webpages in keep flaking out. That is, from time to time, instead of seeing the Flash content, you see a grey box that doesn&#8217;t do anything. It just sits there, mocking [...]]]></description>
			<content:encoded><![CDATA[<p>OK, so you have this sweet new computer (<a href="http://joefleming.net/2009/03/11/my-sweet-new-laptop/">much like myself</a>) running 64-bit Ubuntu like a champ. Except for one thing; Flash elements on webpages in keep flaking out. That is, from time to time, instead of seeing the Flash content, you see a grey box that doesn&#8217;t do anything. It just sits there, mocking you, until you close and re-open either the tab, or in most cases, the browser itself. </p>
<p>I had this happen in both Firefox and Opera. As it turns out, the problem is related to the machine running a 32-bit version of flash with a 64-bit version of the browser. There are 2 ways to fix this: run a 32-bit browser or run 64-bit flash. But, why would you run a 32-bit browser on your sweet 64-bit machine? Well, because there isn&#8217;t a 64-bit version of flash&#8230; or at least, there wasn&#8217;t <a rel="ext" href="http://labs.adobe.com/technologies/flashplayer10/releasenotes_64bit.html">until recently</a>.</p>
<p>I was tired of this problem so I hit Google and looked for a solution. Sure enough, <a rel="ext" href="http://news.softpedia.com/news/How-to-Install-Adobe-Flash-Player-64-bit-on-Ubuntu-8-10-98076.shtml">I found one</a>! Now, I will warn you that the 64-bit Flash is still in Alpha, but i&#8217;ve been running it for a few weeks now without any problems. Here&#8217;s how you can too.<br />
<span id="more-108"></span><br />
Before we begin, <strong>CLOSE FIREFOX</strong>!! That guide will tell you the same thing. I had a friend who borked his entire Flash setup and I have a feeling this is why that happened. Grab the files, write down the instructions, close Firefox and go for it. Personally, I just opened the instructions in Opera and everything worked out just fine.</p>
<p>Start by removing the existing 32-bit version of Flash. If you haven&#8217;t yet installed it, you can skip to the next part. To uninstall it, fire up the Synaptic Package Manager, search for <em>nsplugin</em> and select <em>Mark for Complete Removal</em>. It will confirm that you also want to remove flashplugin-nonfree, click Mark and then Apply.</p>
<p>Next, download the <a rel="ext" href="http://labs.adobe.com/downloads/flashplayer10.html">alpha 64-bit Flash 10 player</a> from Adobe. One last warning: this is alpha software, and I make no guarantees that it will work, or even not ruin everything, nor does Adobe. Note the filename; in my case, it was <em>libflashplayer-10.0.22.87.linux-x86_64.so.tar.gz</em>, so that&#8217;s what I&#8217;ll use in the console instructions below.</p>
<p>Finally, we need to extract the files and put them in the proper places. The guide will tell you to do this through the X interface, but that&#8217;s not my style. Here&#8217;s how to do it from a terminal, assuming you downloaded the flash tarball to your Desktop.</p>
<p><code>$ cd ~/Desktop<br />
$ tar zxvf libflashplayer-10.0.22.87.linux-x86_64.so.tar.gz<br />
$ mkdir ~/.mozilla/plugins<br />
$ mv libflashplayer.so ~/.mozilla/plugins</code></p>
<p>That&#8217;s it. Now start Firefox back up and you&#8217;re good to go! As I said, this fixed my problem completely, so hopefully it&#8217;ll fix yours as well. While we&#8217;re on the topic, I also highly recommend using <a href="https://addons.mozilla.org/en-US/firefox/addon/433" rel="ext">FlashBlock</a> so cut down on flash ads, useless video loading and just generally enhance your browsing experience. And don&#8217;t worry, you can whitelist whatever sites you want so you won&#8217;t have to keep making extra clicks to watch videos.</p>
]]></content:encoded>
			<wfw:commentRss>http://joefleming.net/2009/04/23/ubuntu-64-bit-firefox-and-flash/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
