ree: baby Metroid with pink hearts in its speech bubble (baby Metroid <3)
Ree 💚 ([personal profile] ree) wrote2014-12-03 08:20 am

tempting fate

Well. I accidentally killed the tumble dryer. Insert non-humorous laugh here.

I'm not ecstatic to be hanging clothes to dry, obviously, but I must admit that I'd much rather machine-wash clothes and air dry them than attempt to wash clothes in a tub but have them warm and fluffily dried.

I was in a Mood over the weekend, but despite the machinations of literal machinery, I am hanging in there and feeling more grounded, stable, and pleasant. Yay!

It turns out that trying to parse a FOAF file in SimpleXML is a real downer. FOAF is a subset of XML, which is what SimpleXML was built to parse in a simple way. Right? Except FOAF is built on namespaces and namespaced attributes, which complicates matters. I haven't found a single way to get the single URI that I want! I found a few ways that might work if I understood them well enough to implement them myself, but I don't. Everything I could understand well enough to attempt has failed utterly. I honestly think my best bet is to funnel the XML as a string through a regex to filter out the single datum I want. Should there be a better way to do this? You bet! But I've already spent hours trying "better" ways; now I just want a way that works.

Once I get that FOAF-related project fully working and put a bit of polish on it, I intend to show it off. At the moment, it's pretty ugly; it's basically a programmatic skeleton with no flesh on it yet. FOAF aside, it's been fun to play with. I'm still torn between making a sort of template that anybody could use for their own project, or just tweaking it to suit my exact wants. I'll work something out.

I don't hear the washer anymore, so I probably need to hang the laundry and then get to my morning workout. Ugh. It takes so long to warm up in this cold weather! Being warmed does beat feeling the cold, though.
anke: (Default)

[personal profile] anke 2014-12-03 04:20 pm (UTC)(link)
Saaay, would you give me an example file, tell me what you want to extract, and let me see if I can figure it out? I've been working mostly with HTML rather than XML, but branching out would be good for me.

I never had a dryer here, probably cause I'm used to clothes being line-dried unless there are special circumstances. What has been crossing my mind occasionally lately is how wrong I was with the humidity. See, I bought a dehumidifier thinking I'd need it in the winter, when I couldn't open the window all the time I'm at home, but it turns out I need it in the summer, cause the cold air getting in in winter is really rather dry, particularly when it warms up. [/ramble]