Posts Tagged ‘ASP’

San Francisco 1, Wasteful Excess 0

December 28th, 2007 by smp | Comments | Filed in Life, RANTING

 

 

Don’t really need to explain this, do we?

Via Core77 and LuxuryLaunches

Technorati Tags: ,,

Tags: , , , , , , , , , ,

There is a 12-step program to help even you…

December 24th, 2007 by smp | Comments | Filed in Life, RANTING

I am often chided for my 5-shot, Venti Latte.

Then I saw this.

Yup, it’s a “a 13 shot Venti soy hazelnut vanilla cinnamon white mocha with extra white mocha and caramel”.

Lord help this person when they wake up in the alley behind Starbucks on Christmas Day.

Original image from Core77.

Technorati Tags: ,,,

Tags: , , , , , , , , , , ,

If you need me, I’ll be dead…or in Tucson, whichever comes first

April 20th, 2007 by smp | Comments | Filed in Work

I’ll be in Tucson for work next all next week, staying at the supposedly luxurious Loews Ventana Canyon Resort.

Tags: , , ,

Tags: , , , , ,

Bacon! I smell Bacon!

February 21st, 2007 by smp | Comments | Filed in Life

Sorry to quote a hideous dog treat commercial from eons ago, but this post at the Core 77 Design Blog reminded me of it.

An alarm clock that reminded me of my halcyon days, when carcinogens and fat mattered less to me.

It also reminded me of a passage from Neal Stephenson’s Zodiac describing the all-black breakfast. My copy of this hilarious book is in a bin in the basement, so I can’t quote it directly.

Tags: , , , , , , , , , ,

Idiots, Explosions, and Falling Anvils

December 25th, 2006 by smp | Comments | Filed in Life

Have I told you why I love my wife?

For Christmas, she bought me The Complete Calvin and Hobbes.

Swooooonnn!

Oh, and there were some other presents as well.

Technorati Tags: , , ,

Tags: , , , , , , , ,

Arnold breaks his leg

December 24th, 2006 by smp | Comments | Filed in RANTING

…at a ski resort in Idaho. [here]

Anyone else see this as ironic?

Tags: , , , ,

Paul Fisher dies at 93

December 12th, 2006 by smp | Comments | Filed in Life

Over the last two years, Fisher Space Pans have taken on near iconic status with the leaders (and followers) in the trendy nouveau geek crowd.

Paul Fisher died recently at 93. [via Notebookism]

Having “donated” four space pens to the cosmos through my own absent-minded behaviour, I can say that I have done my bit to help spread the meme.

Paul Fisher, write when you get there.

Tags: , , , , , , , , , , , , ,

Compressing PHP Output

October 3rd, 2006 by smp | Comments | Filed in Web Performance, WebPerformance.Org

A little-used or discussed feature of PHP4 is the ability to compress output from the scripts using GZIP for more efficient transfer to requesting clients. By automatically detecting the ability of the requesting clients to accept and interpret GZIP encoded HTML, PHP4 can decrease the size of files transferred to the client by 60% to 80%.

The information given here is known to work on systems running Red Hat 8.0, Apache/1.3.27, Apache/2.0.44 and PHP/4.3.1.

Configuring PHP

The configuration needed to make this work is simple. Check your installed Red Hat RPMS for the following two packages:

  1. zlib
  2. zlib-devel

For those not familiar with zlib, it is a highly efficient, open-source compression library. This library is used by PHP uses to compress the output sent to the client.

Compile PHP4 with your favourite ./configure statement. I use the following:

Apache/1.3.27
./configure –without-mysql –with-apxs=/usr/local/apache/bin/apxs –with-zlib

Apache/2.0.44
./configure –without-mysql –with-apxs2=/usr/local/apache2/bin/apxs –with-zlib

After doing make && make install, PHP4 should be ready to go as a dynamic Apache module. Now, you have to make some modifications to the php.ini file. This is usually found in /usr/local/lib, but if it’s not there, don’t panic; you will find some php.ini* files in the directory where you unpacked PHP4. Simply copy one of those to /usr/local/lib and rename it php.ini.

Within php.ini, some modifications need to be made to switch on the GZIP compression detection and encoding. There are two methods to do this.


Method 1:

output_buffering = On
output_handler = ob_gzhandler
zlib.output_compression = Off


Method 2:

output_buffering = Off
output_handler =
zlib.output_compression = On


Once this is done, PHP4 will automatically detect if the requesting client accepts GZIP encoding, and will then buffer the output through the gzhandler function to dynamically compress the data sent to the client.

So?

The winning situation here is that for an expenditure of $0 (except your time) and a tiny bit more server overhead (you’re probably still using fewer resources than if you were running ASP on IIS!), you will now be sending much smaller, dynamically generated html documents to your clients, reducing your bandwidth usage and the amount of time it takes to download the files.

How much of a size reduction is achieved? Well, I ran a test on my Web server, using WGET to retrieve the file. The configuration and results of the test are listed below.

Method 0: No Compression
wget www.pierzchala.com/resume.php
File Size: 9415 bytes
Method 1: ob_gzhandler
wget –header=”Accept-Encoding: gzip,*” www.pierzchala.com/resume.php
File Size: 3529 bytes
Method 2: zlib.output_compression
wget –header=”Accept-Encoding: gzip,*” www.pierzchala.com/resume.php
File Size: 3584 bytes

You will have to experiment with the method that give the most efficient balance between file size and overhead and processing time on your server.

A 62% reduction in transferred file size without affecting the quality of the data sent to the client is a pretty good return for 10 minutes of work. I recommend including this procedure in all of your future PHP4 builds.

Tags: , , , , , , , , , ,

Fisher Space Pen and Rite in the Rain: Bonus from a friendly supply sergeant

August 26th, 2006 by smp | Comments | Filed in Notebook Lust

Alan at MREater hit the jackpot when he gave a supply sergeant a lift.

As a bonus he got a Fisher Space Pen. And of course…

It’s the perfect companion to the “Rite in the Rain” All-Weather Field Book the soldier also gave to me. Nothing like a friendly supply sergeant. The Field Book has paper “created to shed water and enhance the written image.” Hot damn. That book is a good piece of gear, the kind of thing you wonder how you ever lived without.

Based on his description, he got a tan Tactical Field Book.

I need to find a supply seargeant to give a lift to!

Technorati Tags: , , , ,

Tags: , , , , , , , , , , , ,

When I regained consciousness…

August 26th, 2006 by smp | Comments | Filed in Life

The title is a play on an old Royal Canadian Air Farce skit.

I have been having an adverse reaction to a new medication, which the doctor asked me to stop taking today. This reaction involves am itchy rash slowly spreading all over my skin.

Tonight I took 1.5 teaspoons of Benadryl to see if that would help.

Well, that’s 3 hours of my life I won’t get back from the sleep goddess.

Tags: , , , ,