10

2003-10 posts.

  1. More Reasons To Like Bush. RE: Politics.
  2. China Puts Yang Liwei Into Space. RE: Science.
  3. Steve: The Cubs Lost. RE: Chicago.
  4. Character Encoding DOH!. RE: Character Sets.
  5. 2004 Toyota Prius. RE: Cars.
  6. Vietnam v Microsoft. RE: Open Source.

2003-10-13t19:59:32Z | RE: Politics.
More Reasons To Like Bush

  1. Gee all these soldiers sent exactly the same pro-Iraq letter? These propaganda letters actually remind me of the soldier letters you guys have been passing around. The propoganda letters smear the real letters. This was one of many botched propoganda campaigns but it makes you wonder about the ones that weren't botched. The liars didn't even have the work ethic to come up with variations of the basic letter.

  2. Antiquities were lost inspite of all the archaeologists who gave lots of stong pre-invasion advice, but we can blame that on one of many details. Drunk US soldiers killed a rare Iraqi tiger, but we can blame that on the weaknesses of particular individuals. However purposely bulldozing 70 year old tree crops is pretty flagrant.
  3. While alpha species are in a recent serious and sudden global decline, Bush is expanding access to endangered species? This is a terrifying policy. This is even worse than his saving the forests by deforestation.
  4. Given this: http://www.awolbush.com/, how dare he wear the flight suit and tell the terrorists to bring it on? Dude, where's my coalition? Of course, the Turks are coming but I don't think our very helpful Kurds will like it.
  5. Bush rushed us in there by instilling fear and fudging intelligence. Saddam was a villain but he was in a box: Clinton used intelligence to make pinpoint attacks that contained Saddam's WMD capabilities. There was no urgency, no connection between Iraq with 9/11 and terrorism, but Bush psyched the connection. He gave us and the UN no choice because he said he would move preemptively and he also preemptively moved troops. The UN's job is to serve and protect its members which consists of sovereign nations. Because Iraq invaded Kuwait, the UN was OK with attacking Iraq. Because the Taliban did 9/11, the UN was OK with attacking Afghanistan. But for this war, Iraq was one nation of many with brutal dictators with a suspect WMD program: that is not a clear and justified reason to invade. Otherwise we should've invaded North Korea.
  6. Of course now that we started the job, we can't abort and we have to finish the job. All the good that is being done in Iraq now is stuff that we should have done with the UN. The US and world schism is unbelievable. Europe, NATO, the UN were working cooperatively with the US global scheme, but by saying we don't need the world, the world also sees that they don't need the US. I believe that Bush has started rocking the US towards a decline.
    • -Asia has a greater GDP than the US. They can make anything we can cheaper.
    • -India is acquiring (has?) all our information ability. Don't we outsource most things there anyway?
    • -OPEC is moving away from the dollar and towards the euro. Russia's oil is doing so as well. OPEC, Europe, and Russia are bonding while the US is separating.
    • -US military might will become meaningless when countries are democratized. Besides hasn't it been proven that a handful of terrorists can make the US spend over $166 billion ($79B up to now, $87B requested, and $??B to be requested shortly afterwards)? Isn't it clear that low tech/low cash can challenge hi tech/hi cash?

Sorry I'm raving, but I wish you pro-Bush guys could show him and his policies in a better light. I know that things are improving in Iraq, and that it will be democratized, but I'm concerned about this isolationist trend (doesn't play well with others) combined with the flux in the Muslim world (with http://www.hubbertpeak.com/ closer than you think).

2003-10-15t14:56:50Z | RE: Science.
China Puts Yang Liwei Into Space

As of today, 2003-10-15, China has become the third country to put a man into outer space. The Shenzhou 5 capsule lifted off at the Jiuquan Satellite Launch Center in northwest China's Gansu Province via a Long March CZ-2 F rocket. The yuhangyuan ("traveler of the universe") was Yang Liwei, 38, a Lieutenant colonel of the People's Liberation Army.

This is good news for space exploration and should help rekindle the field. China has been remarkably open about their space program which shows how well China is progressing into the future in terms of science, political freedom, and economic power (since they also plan to market their space program).

Some people worry about the military and intelligence applications and how this may clash with the usual US tendencies for domination. But my hope is that people will eventually realize that more progress and utility is made by cooperation and competition between nations, than by combat between tribes.

Links: c1 c2 c3 c4 c5 c6 c7

2003-10-16t15:34:30Z | RE: Chicago.
Steve: The Cubs Lost

1908 was the last World Series win for the Cubs, 1945 was the last time the Cubs went to the world series, and this year, 2003, it looked like World Series year! The Cubs needed just one more win in the seven game series to go on to the World Series. It looked like William Sianis' 1945 goat curse was over! But when Steve Bartman stole the foul ball catch from Cub's Left Fielder Moises Alou in the 8th inning of game six (where the Cubs were ahead 3-0), the curse came back on with a vengeance. The Florida Marlins went on to score 8 runs that inning resulting in a Cubs loss of 3-8. The winning spirit was gone. The Cubs then went on to lose game seven yesterday.

Don't blame Steve: he was just catching a ball that was coming at him. And now he's probably the saddest Cubs fan of all. And to top it off: is name will go down with infamy in the annals of Cubs history.

As a North-sider, I'll have to put up with Angel, my South-sider co-worker telling me how sorry he is about the Cubs losing. Big frigging deal! I never got my hopes up! I wasn't going to do anything resembling a little dance unless we actually got to the World Series! Besides it's... it's just a game ... you jerk!

2003-10-20t17:27:55Z | RE: Character Sets.
Character Encoding DOH!

As usual, this story started innocently enough. I opened a JavaScript file in Microsoft Notepad and it was screwed up with familiar symptoms: instead of nicely blocked and nested code, it was all one big blob with all the carriage returns converted into a rectangular block characters.

There are several common explanations for this sort of goofiness:

  • A document is opened in a word processor that enters non-standard non-printing characters, especially if the document was at one time printed to a fancy printer.
  • Systems save EOLs (End Of Lines) and EOFs (End Of Files) differently.
    • Windows systems use a CR (Carriage Return, ^M, \r, 0x0D, or Chr(13)) and LF (Line Feed, New Line, ^J, \n, 0x0A, or Chr(10)) for EOL and a SUB (Substitute, ^Z or Chr(26)) for EOF.
    • Unix/Linux systems use LF for EOL and and no particular character for EOF.
    • Macintosh systems use CR for EOL and and no particular character for EOF.
    • SGML systems use LF for the start each line, CR for EOL, and no particular character for EOF.
  • The document was character encoded in something unexpected. EG: Instead of 7 bit ASCII encoding, another one was used like: windows-1252, iso-8859-1, utf-8, utf-16BE, utf-16LE, utf-32BE, or utf-32LE. This explanation however often has funky characters within words and not just for EOLs.

I tried for the easiest solution first, so I opened the same document up from within Microsoft Word, and, voilà!, it looked just fine. Word was smart enough to either handle the non-standard characters or know how to handle a variety of EOL and EOF variations. I then saved the document with a .txt extension, opened it up in Notepad, and it looked just fine there.

To be even more sure I opened the file using a hex editor (this one made by UltraEdit.com). Bingo! It was a Unix file that used a LF (0x0A) as the EOL.

I was feeling pretty smug and so I immediately proceeded to make a fool of myself.

I thought that it was about time that I made my web site Unicode ready. I looked over utf-8, utf-16, and utf-32. It seemed pretty clear that utf-8 was the best choice since most of my site consists of mostly us-ascii. I thought that this would be fine for several reasons:

  • Unicode is a superset of us-ascii and iso-8859-1.
  • I had used NCRs (Numeric Character References) for code points code points 128-159 (x80-x9F), i.e. the characters that window-1252 implements but which are not part of iso-8859-1. EG: I've always entered the em dash () as either — or — instead of as ALT+0151 (0x97) in windows-1252.
  • I had used NCRs for any characters above 0x255, i.e. beyond either windows-1252 or iso-8859-1. EG: I've always entered pi (π) as π.

WARNING: DO NOT ATTEMPT THE FOLLOWING.

I then proceeded to do a site wide search-and-replace. I changed <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> to <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />. I also changed my xml tags to <?xml version="1.0" encoding="utf-8" ?>.

Sounds good, right?

Wrong. I forgot that utf-8 encodes "Upper ASCII" (code points 127-255, i.e. 0x80-0xFF) as two bytes instead of one like iso-8859-1 does! My arrogance also caused me to ignore the BIG FLAG thrown when anyone does a global search-and-replace.

Unfortunately I was using Microsoft FrontPage which is "smart" enough to know that a character like the section sign (§), which I had entered as ALT+0167 (0xA7), is not good UTF-8 encoding all by itself. FrontPage went on to convert the weird bytes into literal question mark bytes (0x3F). FrontPage could have done a number of different things:

  • FrontPage could have just left the 0xA7 byte as is and displayed displayed either nothing or something (like a block or question mark) in its place.
  • FrontPage could have converted the 0xA7 byte into its NCR sequence: &#xA7;.
  • FrontPage could have converted the 0xA7 byte the correct UTF-8 encoding for the section sign: 0xC2A7.

In contrast, the "dumber" Notepad would have left the 0xA7 byte in place (thinking the document was still a windows-1252 file). I could have then followed up with a Save As... UTF-8, which would have correctly converted the 0xA7 into the correct UTF-8 encoding for the section sign: 0xC2A7.

Now I'm realizing that I've got more High ASCII on my site than I would have guessed. Since I did not catch this problem until a few days after it had been created, and I've modified the site in other way, it is too late to revert to a backup.  My next step is to go through the tedious task of finding all the literal question marks on my site, determining what High ASCII character it might be, and replacing it with the appropriate NCR if necessary. I suppose I should insert the UTF-8 BOM at the beginning of my files too, but I'll leave that screw up for another day.

2003-10-28t16:04:30Z | RE: Cars.
2004 Toyota Prius

Hybrid cars are going mainstream! I got to see someone's 2003 Prius this past Sunday and it looked just like a normal car. I was expecting the trunk to be tiny but, surprisingly, the trunk looked like a regular sized trunk. The dual engines under the hood looked remarkably compact and clean, with a number of things that were clearly not like other cars.

The new 3rd generation 2004 Toyota Prius is faster, larger, and more fuel efficient. The report says that the Prius is as fast as a typical 4-cylinder midsize sedan but it gets 60 mpg with ultra-low emissions, and is eerily whisper quiet. There are only four gear selections: R (reverse), N (neutral), D (drive) and B (braking, i.e. better recharging on hills), but that's fine because that's basically all I ever use on my regular car.

2003-10-30t21:03:02Z | Link | RE: Open Source.
Vietnam v Microsoft

There has been pressure on Vietnam from Microsoft, the US government and the World Trade Organization to cut down on software piracy. Vietnam's creative solution is to eliminate Microsoft from Vietnam!

They are promoting a plan that would require all state-owned companies and government ministries to use open source by 2005. And they would require all computers assembled in Vietnam to be sold with open-source products installed on them.

This is a huge threat to Microsoft. The seeds are being planted, the dominoes will start wobbling. China, Japan, and South Korea are also working on open-source alternatives to Microsoft.

The US is on a dangerous economic trend. Other countries can produce raw materials, manufacture goods, and provide services cheaper than we can. US software, services, and finished goods are generally too expensive for poor countries. US companies are outsourcing manufacturing and services to places like China, India, and Mexico. The icing is that we're running a very expensive war while increasing the US deficit. What’s left for the US to do? Make war profiteering, agriculture and pop culture?

Exploring odd subjects including myself. GeorgeHernandez.com
Some rights reserved
CC by-sa 2.5


GH   GH dir   Wiki   Web
Main Body - Site Map - Contact - About

Timestamp on page load:
    
Timestamp right now: ISO 8601 - RFC 822