Mar. 3rd, 2004

Sigh...

Mar. 3rd, 2004 09:36 am
elfs: (Default)
I got over eight hours of sleep last night. Props to [livejournal.com profile] dakiwiboid for leading me to Robitussin Honey; I lucked out and found a formulation that had dextromethorphan and nothing else and it really worked quite well.

Reading the Dextromethorphan FAQ makes me wonder about it, though. It's a powerful disassociative anaesthetic that, if it were seeking FDA approval today, would never be made available over the counter; the only other drug similar in effect is ketamine. Oh, joy. The government is no help, they have a big "just don't use it recreationally, okay?" I have no intention of doing so; stuff sounds nasty and I'm old enough to buy wine, thank you. A pediatric use guide admit they have no idea if the stuff works in kids.

Y'know what I think? I think the doctor wimped out and recommended 20mg codiene, when the standard dosage is 30mg of dextromethorphan, and the two are supposed to be dosed similarly.

So, I feel better. The fevers and chills are gone, the cough is mostly under control and doesn't bother me in the daytime. I haven't done any writing or coding this week and I'm behind in my language studies because the CD-burner is down with the linux box.

Geek Status )

Took the girls out to a restaurant last night; Omaha and I were dead on our feet and in no mood to cook, and the house was busy with [livejournal.com profile] shaterri moving on to new digs. He was a damn good roommate, but we do live in the boonies. Ah, well. The restaurant was a seafood joint, mid-level, lots of deep fat fried stuff. The girls had shrimp platters, and Yamaarashi-chan ate all of hers. Kouryou-chan was a mess. Wally's (that's the restaurant) supplied us with crayons and sheets with drawings on them to color, blank on the opposite side, which kept them occupied, and dinner came appreciably quickly. They practiced spelling words with one another. It was Yamaarashi-chan's turn to water her plants when we got home, and she was actually rather nervous and twitchy with the watering syringe. We use one of those dosing syringes for babies we had leftover from Kouryou-chan's infancy, since it's small and the kids would have a hard time overwatering with it, but she kept missing the pots (which are only about two inches wide anyway).

Another day...
elfs: (Default)
Under the heading of "why didn't I think of that?" comes this lesson in how to program DTHML called unobtrusive DHTML. The concept behind it is brilliant.

Cascading Style Sheets (CSS) decorate an object in HTML (a list, an anchor, a division of the page) with visual effects such as background colors, text colors, borders, font descriptions, and the rest. This is done with either an object ID or an object class. The way you identify a class is through a modifier inside an HTML tag, what we usually call an attribute. As of IE6 and Moz 1.0, you can now say "find me all of the tags with attribute X that has value Y".

Javascript allows you to "decorate" an HTML object with behaviors-- on mouse over, do this. On click, do that. Usually, the way this happens is that write the complicated function at the top of the HTML page, and then for each object you want to exhibit this behavior, you attach the behavior by adding an attribute such as onmouseout="dothatthing();". Doing this over and over and over is a serious pain in the neck.

Unobtrusive HTML takes care of that. It takes the Javascript "Find me all tags with attribute X that has value Y", and the concept of CSS classes, and allows you to decorate a CSS class with Javascript behaviors. The idea is simple. When the page loads, you say, "Find me all the tags of class 'foo' and attach this onmouseout behavior to them." It's so elegant because it means that spelling mistakes, HTML bulkiness, and Javascript ugliness is eliminated from your code.

And the creator takes in one step further-- by sandwiching your CSS between some initialization javascript and the body of the javascript, you can attach the behaviors to the CSS declaration itself. Along with "font-family" and "border", you can add "onclick" and "onhover" as if they were CSS declarations. That seems to be a bit experimental, but damn... it is way too cool.

Makes my life easier, at any rate.

Combine this with the fact that Mozilla 2.0 will have a backend interpreter with a python (instead of javascript) plug-in, and my luck will be complete, my career assured for a while to come.

Profile

elfs: (Default)
Elf Sternberg

March 2026

S M T W T F S
1234567
8910111213 14
15161718192021
22232425262728
293031    

Most Popular Tags

Style Credit

Expand Cut Tags

No cut tags
Page generated May. 11th, 2026 09:11 am
Powered by Dreamwidth Studios