Testing new code…
Month: December 2001
A modern looking Theme, based on the Radio UserLand icon, with the title on a blue background at the top of the page, links on the left, text in the middle, and the calendar on the right.
This is the default Radio UserLand website, a table-based layout, with a blue banner across the top, content on the left, and the calendar and navigation links in a column on the right side.
RockMom: “Music has power over me and all of us. It transcends time and place, changes perceptions. Surely those who would control others absolutely must forbid it.”
Thanks to all who posted answers to my question about what it means to use a * operator on a list (sequence) in Python.
Michael Bernstein pointed out that  is a list, not a dictionary, Zach found me the docs on python.org, and also wanted to know why I would write 2 * 2 instead of 4 (because I was quoting some code, replacing a variable name with its value), and mom says anything * 0 is 0…
But in Python, that may not be true. I guess it depends on whether you think [0, 0, 0, 0] == 0.
I’m trying to read some Python code today, and I ran into something I don’t understand. What does the following mean in Python?:
x =  * (2 * 2)
If I understand correctly, the value of X after that line executes will be:
[0, 0, 0, 0]
…but I’m not sure. My brain doesn’t know how to parse multiplication of a dictionary object (yet). I’m sure that somewhere on python.org, there are docs about this, but I haven’t found them yet. Anyone know the answer?
I have an admission to declare: Every time I see DayPop, my brain says “Day-Poop”. I wonder what would Freud say?
Here's how to get the current time into your page, in a 24-hour format, European-style — add the following macro to your template:
<%<br /> local (day, month, year, hour, minute, second);<br /> date.get (now, @day, @month, @year, @hour, @minute, @second);<br /> hour = string.padWithZeros (hour, 2);<br /> minute = string.padWithZeros (minute, 2);<br /> second = string.padWithZeros (second, 2);<br /> return (hour + "." + minute + "'" + second)<br /> %>
The macro expands to something like this: 03.36'02
No, I didn't stay away from the computer on Christmas. My dad asked me if I was working, and I said, “What are you kidding?” He thought that meant that I was working. I meant that I wasn't.
Anyway, one of the non-work things I did on my computer was update my MacOS X installation. It cleared up a couple of things. First, icons on my desktop don't end up in strange locations after waking my PowerBook from sleep with the outboard monitor connected. It may seem like a minor thing, but I was very pleased.
The other thing is that now my PC-card adaptor that I use to download pictures from my digital camera's compact flash card works. This is really great because that was the last thing I needed in order to completely wean myself from booting into classic.
I also downloaded the b3 version of the driver I use for my Lucent/Orinoco 802.11b card, and turned my AirPort base station back on. It works! What's more, the rogue DHCP server that was preventing me from using DHCP to get IP addresses from the base station seems to be gone. Someone finally got a clue.
The other thing I did was have a look around Apple's new AppleScript pages. On their Toolbar Scripts page, there's a script you can use to scale images. I copied the scaling bit into a script window in Radio, and did a quick test. Guess what: It works! Someday when I have some free time, I'd like to make a Tool for Radio/Frontier, that implements a couple of image manipulation web services — rotateImage, scaleImageByPercent, scaleImageToSize. These in combination with a Manila plugin would make it possible to completely automate creation of contact-sheet-type pages where you have thumbnails of a bunch of images, that link to the full-sized image. That would be a Cool Tool. Now all I'd need would be a full-time MacOS X server. Have to put that on next year's Christmas list.