Thursday, May 05, 2005
miscellaneous thoughts on an odd-numbered day
- just one of those odd coincidental dates. next year will have “6-6-6” ;-)
- ordered pizza from papa john's, all online, no cash needed. cool.
- the summer haircut is here. and hell, i'll probably go even shorter. this may be mohawk or shaved head year. and it will be, if i don't find work.
- ran into some dude in the neighborhood barber shop parking lot. retired guy - driving a jeep almost identical to mine ! that led to a two hour bullshit session. people like that have the coolest stories. of course we did the requisite jeep bs thing. turns out he's been racing & customizing 'em since his teens. he talked a bit about his trip to alaska in the early 60's - ! life in the indiana boonies. etc. he only moved to the city because his doctor wanted him closer than an hour and a half because of repeated heart problems.
- anyway, i must be getting old, because the only body i was drooling over lately was the one on a jeep ;-)
- still have the hard top on, but the weather got unusually warm, so i pulled the doors off. still haven't washed it. i feel like such a redneck.
- finally mentioned to the landlord that the air conditioning has been broken for years. about time that gets fixed. and the water heater leak is also sucking money. i also have a dryer to fix, but i don't know if it's worth the repair, or if i should get a new one. looking at a gardware store flyer, they've got cheaper large capacity ones for $250, and they'll deliver it and remove the old one for free.
- then again, i really don't want more baggage. ideally, i'd be gone from here. still waiting on word from potential boarders for my
junk, er, “valued possessions“; yeah, that's it ;-)
- current reading: Advanced Calculus : A Differential Forms Approach. i bought this some years back, and it's been itching at the back of my mind ever since. so far, it's eye opening. very cool.
uh-oh - i think the pizza is here !
home page framework; onelementready behavior
so, the content on my CSWeb home page pretty much boils down to this now:
<div
style="behavior: url(styles/transform.htc);"
hrefXML="main.opml" hrefXSL="main_opml.xsl"
asynch="true" load="true">
loading csweb main opml...
</div>
pretty cool, eh ? that's stretching client side processing to one sort of limit. between behaviors, css, xslt, rss and other xml, with a smattering of html for ad-hoc stuff. i can do pretty much anything i want in terms of content, layout, function and appearance in a highly compartmentalized manner. that opml is slightly enahnced for my own use; i've added some attributes for xslt, css assocation and parameter passing.
with this framework in place maintenance is simple. well, if you understand where everything is in the framework, that is. in some senses things a very complex. say i want certain content to appear on the main page in a certain layout, etc. i would add an element to the opml, specify the xml/rss or html content, and optionally xslt and a class name. for these last two optional parts i would also need to create the xslt, and modify the page's stylesheet to add the new class. if any special functionality is involved a behavior may need to be created and attached via the css. maybe not so bad, really. sure is built out of a lot of pieces though.
one side note: to synchronize dom processing some elements have “onready“ type events, typically data containers and the body element. but in general, this event is missing from most elements. well, it's easy to add it with a behavior. voila - no more racing conditions with dom processing. of course, this is only an ie 5+ thing. most of the time when i do this i don't just expose the event, i usually encapsulate the function as well. but a generic onready behavior could be applied across the board if needed to expose the event for use as usual (via script specified on an element attribute).
<PUBLIC:COMPONENT name="behaviorOnReady" lightWeight="true">
<public:attach event="oncontentready" onevent="fn_onready()" />
<public:event name="onelementready" id="evt_onelementready"/>
<public:property name="elementreadystate" get="get_elementreadystate"/>
</PUBLIC:COMPONENT>
<SCRIPT LANGUAGE="JScript">
var m_elementreadystate = false;
function fn_onready() {
m_elementreadystate = true;
var oEvent = createEventObject();
oEvent.result = 0;
evt_onelementready.fire (oEvent);
}
function get_elementreadystate() {
return m_elementreadystate;
}
</SCRIPT>