Utopian Ideals

I have a little joke I make when people ask me how work is. It goes a little like this:

Other Person: How is work going?

Me: Okay, I suppose. I mean, it’s not like work is supposed to be fun or anything. That’s why it’s called ‘Work’, and not ‘Fun’. Can you imagine what the world would be like? “Well, I’m off to Fun now, I want to pop in there and have a little fun for a couple of hours”.

[Other Person walks away…]

Me: Hey, where are you going. Come back…

However, I don’t really believe this. I want to be in a situation where I can do something I love as the main [source of income|thing I do each day]. I read an article which used to be at http://calacanis.weblogsinc.com/entry/1234000540052285/ about this. I guess I don’t necessarily want to be a ‘professional blogger’, although it seems like it might be a fun job. I’d just like to be doing something I like, for the significant portion of my time. I already have a job where I do have a fair amount of time to ‘do my own thing’. If necessary (and meetings permit), I can leave work well before 3:30pm, and I get a fair chunk more holidays each year than the average worker. I don’t think I’d like to give up those aspects of the teacher lifestyle. But there are things about my job that I don’t really like. I’m not going to be too specific, but I forsee myself in the not to distant future not working full time as a teacher. Whilst some people don’t like the idea, and the ‘randomness’ of being a relief teacher (Supply Teacher in the UK, Substitute in the US), I think it sounds better than the alternative.

Not having to do a heap of marking and preparation.

Not having to attend staff meetings.

Not having to attend Parent-Teacher interviews.

Not having an income during holidays.

Okay, at the moment that last one is a bit of a kicker. My aim is to have some other sources of income, something that allows me to work ‘from home’, whether it’s building renovation and maintenance, coding or otherwise. I sometimes feel that my generation is the first one to decide that we don’t have to spend our whole lives working, to support our lifestyles. Our whole lives should be our lifestyles. Life is short. Enjoy every day.

iTunes "Now Playing" CSS

A while ago, I played around with my site StyleSheet, and set it up so that a paragraph of text with the class iTunes had a little icon placed next to it. This seems to have stopped working. Must look into it. Edit: I fixed it. Originally the code was:

1
2
3
4
    .itunes:before
    {
            content:url('/images/itunes.gif');
    }

I changed it to:

1
2
3
4
5
6
    .itunes
    {
    	background:url('/images/itunes.gif') no-repeat;
            text-indent:16px;
            font-size:0.8em;
    }

Strange Referrers

I’ve written about referrer logs before, on various points, but today something strange occurred. I checked my referrer logs just now, and I had nearly 500 hits. Cool, but it’s only early in the (server) day, and I normally only get around 300 for the whole day. So, I checked the logs, and most of them are DIRECT, and point to invalid URLs. The weird thing is that they are all /wp/admin/, and I am the only user. When I try to visit one, it fails:

http://schinckel.net/wp-admin/www.blogsome.com//page/5/

Not only is it a weird URL, with a www.blogsome.com, and /wp-admin/, it’s also got a double slash (//). But otherwise, it nearly points to a valid page (schinckel.net/page/5/ is a valid and active URL). Strange.

Adsense Keywords Value

I was reading up on the WordPress SEO scandal from late March/early April, and a comment I found in it got me thinking about keyword values. I then found a page that offers to sell a list of keywords, that can be used on Overture (a competitor to Adwords/Adsense) to receive high dollar values per click. (I’m not going to link to it, to protect you, loyal reader…) They ask for a payment of US$99. Bargain! (Note sarcasm). I’m not suggesting I’ll get into any SEO stuff, or try to scam Adsense, I tjust thought it was interesting to see how people do make money. Of course, it reminds me of the books you can buy telling you how to make a million dollars. I think the best way to become a millionare is to write a book telling other people how to do it, and sell 50,000 copies at $20 each.

The rise and rise of blogs

Drunken Batman has an interesting post about the failures of trackbacks, and how he is going to remove them from his site in the near future.

He actually makes an interesting point at one stage in the post:

I did put the trackbacks over the comments for a reason, and preferred them over the comments for a reason. In a small way, trackback encouraged people to do their own site, because, well, they had to have one in order to trackback and have their stuff right there front and center and maybe get some hits from it.

I found this quite amusing, especially after this comment I received some time ago:

Blogs have polluted the web. Now, every time I search for a topic, most of the links send me to blogs. I want real information, not some blogger’s thoughts on the matter. How boring.

The irony of this comment is that I originally started a blog so I can post the sort of information I had searched for, and struggled to find initially, and then worked out for myself. My “thoughts on the matter” are indeed egotistical, but I’m like that. People as good as me usually are.)

Daring Fireball: About the Footnotes

Daring Fireball: About the Footnotes John Gruber talks about the use of footnotes in blog posts. What strikes me as a good way to do stuff is to have a multi-line abbreviation-style tag, that floats over the text where the pointer is when hovering.1

Sub-Pages don't work in Blogsome

There you go. Visit http://schinckel.net/software/, and then visit http://schinckel.net/software/acronymmerpy/ No difference, even though there is a page in acronymmerpy/ I’ll put this in the blogsome forums when I get a chance.

acronymmer.py final (?)

Taking into account the comments on PhotoMatt’s acronymit page (where I shamelessly stole some ideas, including the list of words!), I’ve modified acronymmer.py so that it:

  1. Does not apply <acronym> tags to instances that have been acronymmed already.
  2. Does not apply tags to instances that are inside href or title strings.
  3. Does not save the file if no changes have been made.

Here it is, including my current acronym list. (I know some of these are Abbreviations, but ecto, and some browsers do not handle this tag). Also, this code needs to be re-pasted - I was trying to make it (XHTML) valid, and it’s broken now.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
    #! /usr/bin/env python
        
    'A script for ecto that adds abbr and acronym tags to the text'
        
    acronyms = {
    'WYSIWYG' : 'what you see is what you get',
    'XHTML' : 'eXtensible HyperText Markup Language',
    'IIRC' : 'if I remember correctly',
    'HDTV' : 'High Definition TeleVision',
    'LGPL' : 'GNU Lesser General Public License',
    'MSDN' : 'Microsoft Developer Network',
    'WCAG' : 'Web Content Accessibility Guidelines',
    'SOAP' : 'Simple Object Access Protocol',
    'OPML' : 'Outline Processor Markup Language',
    'MSIE' : 'Microsoft Internet Explorer',
    'FOAF' : 'Friend of a Friend vocabulary',
    'GFDL' : 'GNU Free Documentation License',
    'XSLT' : 'eXtensible Stylesheet Language Transformation',
    'HTML' : 'HyperText Markup Language',
    'IMAP' : 'Internet Message Access Protocol',
    'RAID' : 'Redundant Array of Independent Disks',
    'MPEG' : 'Motion Picture Experts Group',
    'JPEG' : 'Joint Photographic Experts Group',
    'CSTA' : 'Central Scorpions Touch Association',
    'CDDB' : 'Compact Disc DataBase (Gracenote)',
    'XBMC' : 'Xbox Media Centre',
    'VNC' : 'Virtual Network Computing',
    'URL' : 'Uniform Resource Locator',
    'W3C' : 'World Wide Web Consortium',
    'MSN' : 'Microsoft Network',
    'USB' : 'Universal Serial Bus',
    'P2P' : 'Peer To Peer',
    'PBS' : 'Public Broadcasting System',
    'RSS' : 'Really Simple Syndication',
    'SIG' : 'Special Interest Group',
    'RDF' : 'Resource Description Framework',
    'AOL' : 'American Online',
    'PHP' : 'PHP Hypertext Processor',
    'SSN' : 'Social Security Number',
    'JSP' : 'Java Server Pages',
    'DOM' : 'Document Object Model',
    'DTD' : 'Document Type Definition',
    'DVD' : 'Digital Versatile Disc',
    'DNS' : 'Domain Name System',
    'CSS' : 'Cascading Style Sheets',
    'CGI' : 'Common Gateway Interface',
    'CMS' : 'Content Management System',
    'FAQ' : 'Frequently Asked Questions',
    'FSF' : 'Free Software Foundation',
    'API' : 'Application Interface',
    'PDF' : 'Portable Document Format',
    'IIS' : 'Internet Infomation Server',
    'XML' : 'eXtensible Markup Language',
    'XSL' : 'eXtensible Stylesheet Language',
    'GPL' : 'GNU General Public License',
    'KDE' : 'K Desktop Environment',
    'STB' : 'Set Top Box',
    'MP3' : 'Mpeg Layer 3',
    'PVR' : 'Personal (Digital) Video Recorder',
    'GUI' : 'Graphical User Interface',
    'CLI' : 'Command Line Interface',
    'AAC' : 'Advanced Audio Coding',
    'IE' : 'Internet Explorer',
    'CD' : 'Compact Disk',
    'GB' : 'Gigabyte',
    'MB' : 'Megabyte',
    'KB' : 'Kilobyte',
    'TV' : 'TeleVision',
    'PC' : 'Personal Computer',
    'NSLU2':'[Linksys] Network Storage Link (USB) 2.0'
    }
    
    
    import sys, re
    data = open(sys.argv[1]).read()
    olddata = data
    
    # replace only the first instance of each acronym/abbreviation
    for each in acronyms:
        d = re.search(r'(?!<.*(title|href)='*>)?\b%s\b(?!(.*'>|</acronym>))' % each, data)
        if d:
            data = data[:d.start()] + '<acronym title='' + \
                   acronyms[each] + '>' + \
                   each + '</acronym>' + data[d.end():]
        
    if data <> olddata:
        open(sys.argv[1],'w').write(data)

Updated: acronymmer.py for ecto

I’ve improved acronymmer.py, my script for adding acronym tags to posts in ecto. It will work with any file, however, that is passed as an argument to the script. There is one issue with ecto, and that is that abbr tags are not recognised by the Rich Text parser, so I’ve just set it to convert tags to acronym only for the time being. (Note to Adriaan: You should fix this!) Don’t run this script over the same text twice: it will re-tag them, resulting in messy (but still legal) code. Also, this needs a little fixing: the dictionary of items needs to return keys in size order, rather than just randomly.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
    #! /usr/bin/env python
        
    'A script for ecto that adds abbr and acronym tags to the text'
    
    import sys, re
        
    acronyms={'WYSIWYG':'What You See Is What You Get', 
              'DOM':'Document Object Model',
              'XHTML':'eXtensible HyperText Markup Language',
              'NSLU2':'[Linksys] Network Storage Link (USB) 2.0'
             }
        
    # get input data - depends on implementation.  For ecto:
    data = open(sys.argv[1]).read()
        
    # replace only the first instance of each acronym/abbreviation
    for each in acronyms:
        d = re.search(r'\b%s\b' % each, data)
        if d:
            data = data[:d.start()] + '&lt;acronym title="' + \
                   acronyms[each] + '"&gt;' + \
                   each + '&lt;/acronym&gt;' + data[d.end():]
        
    #return data to ecto
    open(sys.argv[1],'w').write(data)

Strange Comment Spam

I checked my blog comments this morning, and got quite excited. Normally I get a comment or two per week, but today there were 11 new comments. And they were for a variety of different posts, ones from recently and some from quite a while ago. I clicked on the Comment arrow in the Dashboard, and was intrigued to see they were all meaningless jumled letters. 11 comments, all spam, all with 2 links in them, all not pointing at anything in particular. I mass-deleted them, but probably should have inspected them a little more closely first, just to see what the story with them was. I did notice they all came from different IP addresses, all used reasonable first names as the Commenter Name, and all had the same set of character in them: erdfcv. A quick Google on this provided not many clues. There is a user on immigration.com forums, and an eBay user, and a whole lot of foreign (non-English) language pages. Chinese, Arabic, Polish, Hungarian, and Korean, to name a few. Then I looked at the keyboard.

qwERt
 asDFg
  zxCVb    

I’m such a tool, this is not a random set of strings, but a common(ish) method of coming up with a set of letters. Like QWERTY but less recognisable.