Done, and gets things smart.
Sigh. I’ve just spent the last few hours wandering around the various “open source” analytics programs trying to find the exact right fit for what I want. I’m not finding it, which means that (headache ahead) I may have to write something myself. There’s a django-analytics placeholder in GoogleCode, but it’s empty. I at least [...]
16Sep
Posted by Elf Sternberg as django, python, web development
Today’s little snippet: Filtering a loosely coupled many-to-many relationship. As revealed earlier, I don’t really “get” the difficulty with many-to-many relationships. I don’t even get the difficulty with signals; if you define the many-to-many manually, handling signals on it is trivial compared to trying to do it manually in one of the referring classes. Today, [...]
Repeat after me: Registration is not Authentication is not Authorization is not Utilization. Registration is not Authentication is not Authorization is not Utilization. Registration is not Authentication is not Authorization is not Utilization. I’ll keep reminding myself of that until I figure out how to disentangle the four from this damned Facebook app. Registering to [...]
It seems like such a stupid thing, but hey, now I know how to use CSS sprites. Basically, it’s the same idea as a viewport slider: treat your rectangular space as a viewport onto a background image. By using the background-position attribute and the .css() control (in jQuery; there are others in other libraries), you [...]
05Sep
Posted by Elf Sternberg as javascript, programming, web development
I spent a good two hours figuring out how to do this and so I’m gleefully going to share it with you. Those of you with small monitors (or other strange habits) might have operating system dock (the thing at the bottom or top of the screen that you use to start programs, check the [...]
20Aug
Posted by Elf Sternberg as django, programming, web development
One of the nifty things that Django provides is the {% url backreference %} syntax, which allows you to name the targets in your list of URL objects and then refer to them by an explicit name. You can sometimes use the function name instead, and Django has a way of turning the function name back into the [...]
29Jun
Posted by Elf Sternberg as django, programming, python, web development
One thing I see a lot of in professional Django is the importation of ugettext, Django’s internationalization library that leverages the GNU gettext project’s toolkit for generating translation catalogs. Laying the groundwork for translation is important to larger projects intended for universal appeal. Because the underscore is a valid leading character in a function name [...]
26Jun
Posted by Elf Sternberg as django, programming, python, web development
At del.icio.us (and some other sites, but I’ll use del.icio.us as my example), one of the most interesting features is that your username is one of the first-level “commands” you can send to the application: “http://del.icio.us/elfsternberg” is a valid URL, and points to my collection of bookmarks. At the same, there are other first-level commands [...]
14Apr
Posted by Elf Sternberg as programming, ruby, web development
So, remember my comment about unit testing yesterday? This is what it looks like today. Here’s the features page: Feature: Login In order to use the system As a customer I want to log in Scenario: Access page Given I am at the login page Then the page title should be “SecretProject” Scenario: Log in [...]