Texas GOP’s new web site on kludge

Posted in Politics, Technology, Web on November 20th, 2009 by Aren Cambre – Be the first to comment

The Texas GOP recently rolled out a new web site at http://www.texasgop.org/.

If you surf it, you’ll see asp file extensions. For example: http://www.texasgop.org/inner.asp?z=6

That means the Texas GOP’s runs its brand new site on a kludge CMS!

“Woah, Aren, isn’t that severe?”

No.

ASP’s most recent version is from 1999.

Microsoft replaced it with ASP.Net 1.0 in January 2002. ASP.Net is now on 3.5, and 4.0 is around the corner.

Vendors still delivering classic ASP code in November 2009 have colossally failed to invest or innovate and may be incompetent.

When I review products, those still on ASP start out such a disadvantage that they’ll probably never make the selection.

What is up with the Texas GOP? How did it get hoodwinked into a kludge CMS?

PEAR Text_Diff doesn’t split words on punctuation

Posted in Technology, Web on November 9th, 2009 by Aren Cambre – 1 Comment

The PEAR Text_Diff system’s inline parser has a silly word splitting algorithm: it only defines word boundaries as spaces or newlines (\n).

This causes problems with punctuation. Suppose you are diffing the following two sentences:

The quick cat jumped over the lazy fox.
The quick cat jumped over the lazy dog.

The final rendered output will look like this:

The quick cat jumped over the lazy fox.dog.

Notice how the period is included in the word boundary? That makes messy markup. This comparison is worse:

The quick cat jumped over the lazy fox, who was totally lazy and should be shot.
The quick cat jumped over the lazy fox.

Here’s how PEAR Text_Diff does the diff:

The quick cat jumped over the lazy fox, who was totally lazy and should be shot.fox.

This final diff is difficult to read. You are not deleting and reinserting fox, you are in fact just changing the punctuation on its right. But because the inline diff renderer only considers space and newline as word boundaries, it doesn’t catch this basic punctuation issue.

The fix took me 1.5 hours of PHP code review to figure out the system, but it’s painfully easy to do it. Edit PEAR/Text/Diff/Renderer/inline.php. At lines 158 and 159 (per the online source code), you’ll see " \n" at the end. That is a collection of word boundaries, passed as a mask to the PHP strspn function. Simply add your word boundaries between the quotes, and the diff engine works correctly.

I’ve reported this as PHP PEAR bug 16774.

Return to Innocence does not feature an American Indian

Posted in Aren, Boy Scouts, Interesting, Memories on October 26th, 2009 by Aren Cambre – Be the first to comment

noac_1994_patchThis may surprise attendees of the 1994 National Order of the Arrow Conference (NOAC).

Order of the Arrow is an honor society of Boy Scouts that uses American Indian imagery.  The 1994 NOAC conference’s closing ceremony prominently featured then-popular Return to Innocence by Enigma in an Indian-themed ceremony.

Only problem is that’s not an Indian voice. It’s an aboriginal Taiwanese chant.

So now you know. The NOAC planners are probably blushing.

Here’s the song: http://www.youtube.com/watch?v=-JpJjsHgYHA

Google Street View Says I’m Republican

Posted in Aren, Humor, Politics on October 9th, 2009 by Aren Cambre – 1 Comment

…and it’s right!

New imagery of my front yard, probably from October 2008:
frontYardGoogleMaps
Those are all Republicans.

Google also knows my across-the-street neighbors’ opinions about my signs. Look where they faced their signs. (Hint: Google camera’s straight-on view means they’re not facing drivers!)
1015erin 1023erin
Silly liberals!

See the whole scene for yourself. Pan around to see my neighbors.

Texaco Star Academic Challenge: Aren on TV!

Posted in Aren, Interesting on September 28th, 2009 by Aren Cambre – 5 Comments

Below is is my Texaco Star Academic Challenge performance from 1993 or 1994. Yes, Clear Brook High School made it to TV.

At least wait through my part of “meet the contestants.”

Get the Flash Player to see this video.

Doctoral update

Posted in Uncategorized on September 16th, 2009 by Aren Cambre – Be the first to comment

I have significant updates on doctoral progress for my wife and me. No, we’re not imminently graduating, but still good news.

Jennifer completed all her major doctoral steps before Ethan was born. That means all she has left is being hazed putting in her research time until it is considered “enough,” whatever that means. Then she does the dissertation.

The dissertation is around 200 pages but not as hard as it sounds. Huge swaths are already in Jennifer’s prior papers and reports. I’ll be $1 she’ll graduate in a year or less; she’s not as confident.

I am finally progressing on my own praxis. I finished all coursework in December 2007 and then accomplished nothing in the next 1½ years. Well, I did do things, including aborting an impossible praxis topic and considering switching to a PhD program.

The PhD would have been in Civil Engineering with emphasis in Traffic Management. My M.S. Computer Science and D.E. coursework matched up almost perfectly. All I would have had to do is two more 3 hour courses and a dissertation. But it is not the great deal that it may sound like.

First, I am genuinely interested in traffic operations. However, I have no other civil engineering background, so I would not have been very employable as a traffic engineer. Even then, I am not sure I want to work in a transportation department. Career-wise, it didn’t make much sense.

Second, it is enough of a challenge just to do the 12 hour praxis for my Doctor of Engineering. This is the first time in my life that I’ve had to say “no” to so many invitations for events or volunteer activities. My free time crunched a little with the arrival of the second kid (but not as badly as everyone says it does!), and praxis work easily expands to gobble any leftover time. Not only is a PhD dissertation twice as many hours, the topic is completely original–as opposed to the praxis’s practical orientation–so the work is more difficult. On top of that add 6 more course hours, and I just don’t know if it would have been achievable.

Third, the largest difference between a PhD and Doctor of Engineering may be eligibility for tenure-track professorship. My department chair likened it to the “union card” of tenure. Since I do not aspire to that, PhD has no additional professional merit for me over the D.E.

What’s my praxis topic? I am studying whether there is a statistically sound way to correlate trends in ticketwriting, motorist behavior, and safety. For example, does writing a lot of tickets cause a safety benefit? All prior studies appear to be highly localized, like trying to answer how long after seeing enforcement activities do motorist revert to non-compliant behaviors. I am attempting a broader or systemic approach. I hope my research may be good enough quality to be published in transportation journals and meaningfully guide jurisdictions.

I am collecting data on all traffic tickets written by Dallas County’s 33 jurisdictions. This includes 31 cities with boundaries in the county, the county itself, and the Texas Department of Public Safety. So far I have data from 10 jurisdictions, and several more are currently working on my request.

Most cities have been amazingly helpful. I’ve had a few frustrating sticks in the mud, but they are the exception.

Jennifer and I have come a long way, but we still have a year or so in front of us. Wish us luck!

Shattery front door

Posted in Interesting on September 7th, 2009 by Aren Cambre – Be the first to comment

My glass storm door shattered yesterday. Opening the wood front door made a vacuum that made it give up. It wasn’t that hot, so I guess the glass may have had a defect or other stressor that finally gave up.

A neighbor across the street heard the shatter. He was outside for a while before I opened the door, and he and I think he would have noticed if my glass was already shattered but still in place before I opened it.

A new door is only around $200, and the current one’s warranty does not cover glass, so we’re just going to buy a new door. I’ll throw it up over the next few weeks.

Looking from the front:
IMG_2473

Detail view of shattery glass:
IMG_2475

Enterprise Rent-A-Car deletes side air bags

Posted in Traffic Safety on August 18th, 2009 by Aren Cambre – Be the first to comment

According to the Kansas City Star, Enterprise Rent-A-Car deprives renters of an essential safety item.

Enterprise ordered around 66,000 Chevrolet Impalas with standard side curtain air bags deleted. Every retail Chevrolet Impala buyer gets this, but Enterprise’s renters don’t.

This is important: to save $175 per car, Enterprise deprives renters of a critical safety device. Even worse: much of this upfront cost is earned back once the car is sold. And the worst: when renting and finally selling off these vehicles, Enterprise declined to clearly inform that this car is missing an essential safety feature.

Some studies suggest side air bags give up to a 50% crash survivability improvement in side collisions. Consumer Reports strongly recommends side air bags in all car purchases.

Now I will think twice before renting a car from Enterprise.

(Props to The Truth About Cars for finding the article.)

Gallery 3, Windows 2008 R2, and IIS 7

Posted in Technology, Web on August 18th, 2009 by Aren Cambre – 5 Comments

EDIT: Gallery’s maintainers decline to fully support Gallery 3 on IIS. See http://gallery.menalto.com/node/90281 for more info.

Yes, you can run Gallery 3 on Windows 2008 and IIS 7. Here’s how I did it:

  1. Clean install of Windows 2008 R2 x64. NOTE: These days, 32 bit is pretty ridiculous. The instructions below are only guaranteed to work on x64.
  2. Install the Web Server (IIS) role. I think this will also force a portion of the Application Server role to be installed, too.
  3. Install PHP 5.3. Just go through the default installation steps. I used the latest VC9 x86 Non Thread Safe version from the Windows binary download page.
  4. Install MySql Community Edition for Windows x64. I used default options through the process.
  5. Download phpMyAdmin. Unzip and copy files to C:\inetpub\wwwroot\phpmyadmin.
  6. Visit http://localhost/phpmyadmin, sign in using your MySql’s root account, and create a new database for Gallery 3.
  7. Download Gallery 3. As of this writing, the latest version is beta 2.
  8. Extract files and place in C:\inetpub\wwwroot\gallery3.
  9. If you run Gallery right now, it will squawk about missing some PHP settings that are in its .htaccess file. That file is not read by IIS, so you must implement differently:
    1. Create C:\inetpub\wwwroot\gallery3\.user.ini (more info on .user.ini) and open with a text editor. (Might need to use Notepad launched as administrator because of the protection Windows gives to files in C:\inetpub\.) Yes, you do need the period before user in the filename.
    2. Add these lines:
      short_open_tag    =    1
      magic_quotes_gpc   =   0
      magic_quotes_sybase =  0
      magic_quotes_runtime = 0
      register_globals  =    0
      session.auto_start =   0
      upload_max_filesize =  20M
      post_max_size =      100M
      date.timezone = "America/Chicago"

      Note that the date.timezone is because of an additional problem with Gallery 3’s underlying Kohana framework and PHP 5.3 (link).
  10. Create a new directory at C:\inetpub\wwwroot\gallery3\var. Edit its permissions and give the Users and IIS_IUSRS groups Modify permissions. NOTE WELL: Generally, you should use the principle of least privilege and only give enhanced privileges to the smallest number of users possible, which means not the Users group. I’ll revise in the future if I confirm that only IIS_IUSRS–or even a specific account–is all you need.
  11. Set up mod_rewrite:
    1. Download and install the URL Rewrite Module x64.
    2. In Server Manager, click on Server Manager > Roles > Web Server (IIS) > Internet Information Services (IIS) Manager. To the right, find your gallery3’s directory under your web server under Sites. Click on that directory.
    3. Click URL Rewrite then Import Rules…
    4. Copy the mod_rewrite rules, including the IfModule directives, from the end of Gallery3’s .htaccess file and paste into the Rewrite rules field of the Import mod_rewrite rules screen. Remove the # characters at the beginning of each line; otherwise, they are just code comments.
    5. Delete the line containing RewriteBase. It is not supported, and the rules will not import until that is fixed.
    6. Click Apply on the right hand side.
  12. Now run Gallery 3 setup at http://localhost/gallery3.

Viola, you have Gallery 3 on IIS.

This may seem like a lot of steps, but it’s actually not much different than a setup on Ubuntu. It’s easier than how it used to be with IIS 6 or PHP 5.2. Kudos to Microsoft and The PHP Group for a dramatically easier setup process.

Re: 6 door Ford F-250 work truck

Posted in Interesting on August 3rd, 2009 by Aren Cambre – Be the first to comment

Jeremy Callahan found the answer to the 6 door work truck question: made by Custom Autos by Tim of Guthrie, OK, and the exact truck is at http://www.customautosbytim.com/8.html.