This site will look better in a browser that supports Web standards, but it is accessible to any browser or Internet device.

Archive of February, 2004

1993
2001
2002
2003
2004
January
February
Su M Tu W Th F Sa
1 2 3 4 5 6 7
8 9 10 11 12 13 14
15 16 17 18 19 20 21
22 23 24 25 26 27 28
29            
March
April
May
June
July
August
September
October
November
December
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020

[Permalink 2004-02-27] Dang

February 27, 2004:

Wednesday I forgot to helpfully mention to the Catholics and Eastern Orthodox types that they've got some crud on their foreheads. What fun is it being a jerk if it slips your mind?

[Permalink 2004-02-26] Pleeeeeease Get Signal

February 26, 2004:

Just got off the phone with Dish Network; they're going to attempt an install this Sunday. For the Top 60 package, local channels, install and DVR it'll cost me about what I'm paying for cable, and I'll be able to get Sci-Fi Channel again. Thanks to their promotions the dish and DVR are free (I have to return them should I cancel the service) and I get the price of my install back on my first bill.

As long as I can get a signal out my window since the landlord won't let me stick the dish on the side of the building.

[Permalink 2004-02-24] 'Cause this Has Worked So Often Before

February 24, 2004:

Well, it's almost time for my mostly-annual half-assed attempt at getting some exercise. This time I'm not just going solo, however, since my inherent laziness usually kicks in in less than three weeks.

Nope, this time I tried to find a group activity, and Shields pointed me at Pittsburgh Ultimate, where it seems they dislike it when people point out that they're playing frisbee. Anyway, I'm hoping that I'll get more and better exercise than I did rollerblading, and a reason to continue for more than a couple weeks. Now I just have to wait for the commisioner of their spring league to answer my e-mail about when sign-ups start.

[Permalink 2004-02-23] My Latest Attept at Staying Topical

February 23, 2004:

There's been a lot of stuff in the news about gay marriage lately. People seem to be really pissed about it, too. Somehow letting two guys go through the pain of a divorce is worse than Britney Spears running off to Las Vegas for 55 hours of marital bliss.

Anyway, here's my take on it: People are conflating two concepts that unfortunately carry the same name. On the one hand you have a church marriage. A huge affair, complete with overpriced one-off clothing, goverened by a priest of some sort. On the other hand there's the civil marriage, in which a consenting couple signs what is essentially a contract in front of a couple witnesses and a notary.

Chruch marriages can double as a civil marriage; priests, I believe, are allowed to notarize the mariage license. Likewise, churches that haven't met certain state criteria can create a spiritually binding marriage but not a legally binding one. (Pagan/Wiccan marriages come to mind here.) And of course, you can go down to the courthouse and sign the marriage license with no big ceremony. Only the first and third are recognized by the state. Without the paper you ain't married.

Now, people seem to think that, if gays are allowed to marry, they'll be forcing the church to do something it doesn't want to do. At least that's my guess, because that's the only reason people would be so vehement about it. But of course that isn't what is implied; only that two men or women would be allowed to go downtown and sign a piece of paper like is currently happening in San Francisco.

From neither a legal standpoint nor an ethical one can I see reason to prevent gay people from taking part in a civil marriage. Call it a "civil union" if you will, but you have to call a straight couple's that too, and they have to be the exact same thing. Equal protection and all. If people want a church marriage, let them find a church that will marry them; to the state the religious ceremony is irrelevant.

And enough of this "sanctity of marriage" garbage. Marriage hasn't been sacred in a long time; half the people who try it get divorced. Frankly, I think gay people are lucky in that they don't even have to consider dealing with it given that marriage doesn't really accomplish much of anything. So, all you "sanctity of mariage" types: Just come right out and say "Ah don't like dem faggits" so rational people can dismiss you for the 'tard you are.

[Permalink 2004-02-20] Progress... ^%#(&*

February 20, 2004:

For the client project I needed a rich text editor (RTE). I found one on a Web site that matched my criteria: free. It only worked for one RTE on a page though, and I needed three. Took me a couple days, but I got it working.

Now I've got another client, and they also need an RTE. And only one on the page, great. Go to the site, download. Hmm, that looks new.

Turns out the guy made it able to handle more than one per page about three weeks after I downloaded my copy. Glad to know I did all that work basically for nothing.

[Permalink 2004-02-19] Tales of Stupidity

February 19, 2004:

A few weeks ago I went to the Japanese store on Ellsworth to pick up some pocky. I'd never tried the stuff, and I wanted to see if it was any good. I have a vague idea of what I'm looking for, so I wander up and down the aisles looking for chocolate-covered sticks.

After a minute I give up and ask at the counter. The girl points behind me. Ah, must've missed it. There, looking me right in the face, is the word "Pocky". The only damn thing in the store written in English. And I walked past it to ask where it was.

Don't mind us idiot roundeyes; we'll wander in front of buses on our own soon enough.

[Permalink 2004-02-17] Two Weeks In, Feeling Fine

February 17, 2004:

Odd... Last time I was on the Atkins Diet I was ready to kill for a Biggie Fries by the time my two weeks were up. This time, though, it's not really a big deal. Inconvenient, yes, but I'm not really jonesing for a candy bar this time around. I'm not really sure why, either; it's not like I'm having much more variety in my meals.

Oh well. I'm still losing weight and that old adage about gift horses' mouths is rattling around in my head.

[Permalink 2004-02-16] Much More Amusement than I Can Provide

February 16, 2004:

www.actsofgord.com.

I want these stories to be true so very badly, but I'm sure they're not. At least, not all of them.

[Permalink 2004-02-13] Another Asterisk?

February 13, 2004:

Looks like Barry Bonds's trainer has some 'splaining to do. If it turns out that Barry was juiced (keeping in mind that McGwire was too), what are the record books going to look like?

Ruth, George Herman "Babe"  60    (1927)
Maris, Roger 61* (1961)
McGwire, Mark 70** (1998)
Bonds, Barry 73*** (2001)

* 162-game season vs. 154.
** Bulked up with androstenedione and creatine.
*** Bulked up with anabolic steroids, human growth hormone and EPO.

[Permalink 2004-02-12] Viruses

February 12, 2004:

Well, the MyDoom virus is set to peter out this week. But have no fear, The Register says there are more viruses looking to exploit the backdoor MyDoom creates to launch their own DDoS attacks. And everyone who has the slightest inkling of computer security is once again rolling their eyes at the idiots.

Y'know what? I'm sick of reading about DDoS attempts on windowsupdate.com, or sco.com, or microsoft.com. That's not high-stakes enough. Even if some retard opens the HappyFunFile.jpg.exe attachment he receives, it doesn't really do any harm to him. All the people on his mailing list who get spammed, yes. People who want to use the site being targeted, yes. People who just want to use the Internet and are slowed down by all the virus traffic, yes. But the idiots either don't know or don't care, and their machines become a clearing house for script-kiddies.

I want a different virus. I want one that deletes the contents of the idiot's hard drive then runs ZeroFill a couple times to make sure the data can't be retrieved. It will then install DOS 1.0 and create a file called DUMBFUCK.TXT that, when opened, will say: "This is what you get for opening attachments in an e-mail, just because it came from someone whose name sounds slightly familiar to you, even though it's poorly-spelled, completely ungrammatical and filled with strings of random letters. What in the hell were you thinking?"

Maybe when people start getting bludgeoned by their own stupidity they'll get a clue. If not, at least there'll be one less person online who doesn't deserve a computer.

[Permalink 2004-02-10] I'm a Dumbass

February 10, 2004:

Part of my job setting up the client's server was to buy new backup tapes for their tape drive. Since none of them knew what type of tape was required (you wouldn't believe how many different, incompatiable types their are, even by one manufacturer) I tried Dell's site.

The site, in a word, sucks. I could get a list of tapes, or a product page for the tape drive, but in neither place could I find out which tapes go with which drives. So I poked around online, and got the information I needed. Four days or so later, I have two backup tapes, and I'm ready to rock.

Except they were the wrong kind. You mean not everything on the Internet is true?

I call up Dell to arrange the return, and get an Indian guy with a passing familiarity with the English language. (This was a Saturday; I'm not surprised.) I get that taken care of and transfer over to sales, and I'm suddenly missing Indian Dude. This guy spoke English well enough, but I felt like I was saying everything twice. I know I mumble, but I can't be that bad.

Anyway, the correct tapes are now on their way. Since it was my foul-up I'm not asking the client to pay for the increased shipping costs (I had it sent second-day this time) or for the cost of the return shipping. I figure, again since it's completely my fault, that I'll eat any restocking fees too, but that shouldn't happen since all they need to do is re-shrink-wrap the things.

And I've set the delivery date back a week. Wonderful.

[Permalink 2004-02-09] In Touch with My Inner Carnivore

February 09, 2004:

I've been on the Atkins diet for a week now. I've lost about 6 pounds so far, though the sugar cravings that are supposed to go away haven't. Now to see if I can make my goal weight of 170...

[Permalink 2004-02-06] Re-Meming

February 06, 2004:

My map of visited countries isn't very impressive. And I only get that big red blotch in Asia because they re-absorbed Hong Kong :)

Countries I've Been To

[Permalink 2004-02-05] Heredity Can Be a Bitch in Both Directions

February 05, 2004:

Got an e-mail from my mom last night. Pretty normal stuff, except for: "I actually managed to lose my temper today and told [the boss] he's a jackass. Oh God...tomorrow should be interesting."

I really hope she doesn't lose her job; finding new work at 50 is a little harder than finding new work at 26. Actually, I hope she keeps her job, sends out resumes, gets a new job, and tells the boss what she thinks of him in great detail while handing in her two weeks' notice.

(Why yes, the Irish genes come from Mom's side of the family. Why do you ask?)

[Permalink 2004-02-03] The Boob and the Tit He Uncovered

February 03, 2004:

Well, how about that. I skip the Super Bowl halftime show, and this is what happens. Everybody's up in arms over it, too. The FCC is investigating, and CBS received about a bazillion calls right after it happened. Tivo says they had their biggest usage spike ever as people kept rewinding for another look: "What that Janet Jackson's boob?" *rewind* "It was! Hey, everybody, Janet Jackson's boob!" *rewind*

Was it a "wardrobe malfuction"? I doubt it. The leather piece was built to be removed; you can see the snaps in the close-up on Drudge Report. The red frilly thing was probably a bra during the rehersals, but my guess is that she switched it before the show -- it "ripped away" too cleanly and there's the matter of the pound of hardware she was wearing underneath. The nipple ring is fine, but I doubt anyone would go through the trouble of mounting that sunburst thing on it if it wasn't going to be shown.

Was Justin Timberlake in on it? Doubtful. I mean, just look at the guy. I'm surprised he can remember the lyrics he has to lip-sync, never mind taking part in a scheme to show the world some titty. The guy basically looks too dumb to lie.

So, why did she flash the world? My guess is that since her career's been non-existant for the last however-many years she wanted some publicity -- I hear she's got an album due out soon -- and decided she'd like to get people talking about her without her having to spend a dime. Well, it worked.

Doesn't mean the CD won't be crap, though.

[Permalink 2004-02-02] Fun with Programming

February 02, 2004:

This one's going to be full of computer-related stuff. If you know what I'm talking about this may bore you. If you don't do this on a regular basis you probably won't care.

There are a few things in the client site that I'm not entirely pleased with, even though they work well enough as they are. In the interest of getting things done quickly I made a lot of closely-related functions instead of one general-purpose function. I don't really like that -- things are harder to find, and the pages take a tiny bit longer to load on the server since the includes are larger.

I have a few options, the most tempting of which is to just blow it up and start over. Not the best choice by a long shot though. The easiest choice is to just leave it alone, but that has its own problems, like having a lot of redundant code sitting around.

Which leaves a gradual rewrite. The methods change a little bit depending on which programming language you use, but the basic idea is the same: Change as little as possible and switch everything else over when you can.

As an example, right now I have a function called reQuote that fixes up information coming out of a database. It has two functions that look a lot like it: reQuoteNoP, which ignores paragraph breaks, and reQuoteRTE which populates rich-text editors, like IE users see in Hotmail. About 2/3 of the code is similar, and they should be the same function, but it was just easier to hack out three copies and move on. Now I want to fix that.

First rule: reQuote should keep the same functionality during the rewrite. In Java this would done by overloading, or writing a function with the same name but different parameters. In PHP, though, this is done with optional parameters. I add a parameter to the end of the list and assign it a default value. As long as I make the default value what will make reQuote do what it does now, I'm living up to the first rule.

Second rule: Make the code as easy to follow as possible. If my options are to do A-D-E, B-D-F or C-D-G, then I should write something like
if (option 1) {
    A; D; E;
} elseif (option 2) {
    B; D; F;
} else {
    C; D; G;
}
to take care of it, instead of writing an if-elseif-else for the first step, writing the second step, then writing another if-elseif-else for the third step. That may be more correct (saving duplication of D) but I think it causes more problems than it solves.

Third rule: Test as you go. Once the new version of reQuote is working, add options one at a time and test one at a time. Once reQuoteNoP's functionality is duplicated and verified I can do a global search and replace, but there's no sense in breaking everything until it works right. Ditto for reQuoteRTE.

Fourth rule: Decide on optional parameters. Once everything is under the new-and-improved reQuote's control, decide on whether the new optional argument stays optional. In Java it's not such a hot idea since you handle "optional" arguments with overloading, so you're still writing and maintaining two copies of your code. PHP makes it easy to keep optional parameters though, and sometimes I use them. My dividing line is how differently the function acts with each parameter. In this case all the work reQuote does is about the same so I'd make the parameter required. If you go that route make sure you add the parameter to each call of reQuote before making it required, then test each page to make sure it's not broken.

In some cases, though, it makes more sense to me to keep a parameter optional. In the client site I did, I have a function called checkAdminAccess. Its first parameter is a particular bit of SQL to check, specific to where you are in the site: Does the user have access to modify users? To create a new project? That parameter is optional; when it's not present the function checks every single admin permission, essentially asking if the user should be there by any stretch of the imagination. I did that because as the project goes into later phases, there will be more admin functions, and a wider range of people will be able to see the list. Keeping that inside the function lets me change it in just one place.

The second (also optional) parameter determines what to do if the check fails. In some cases, simply failing is OK. I don't show a portion of a page and the user is none the wiser. But when the parameter is absent a failure redirects to a "permission denied" page. Since the action is so different I felt justified in making it optional.

Fifth rule: Once you're done, don't throw out the old code. Cut-and-paste it into a new file with a useless extension (maybe call it "old.code") and keep it nearby in case you ever need it for something. Dreamweaver, which I learned to like once I got it to stop "helping" me, lets you filter out files by their extension when you do an update; adding ".code" to its ignore list keeps your junk code off the server.

And that's all. Well, if you're a non-programmer, congrats on making it through that crap. If you are a programmer, feel free to tell me why I'm wrong :)

This page's URL is http://jasonfleshman.org

This page last updated Jul 19, 2019 4:07:42 PM.