{"id":101,"date":"2005-02-09T09:48:18","date_gmt":"2005-02-09T07:48:18","guid":{"rendered":"http:\/\/www.ericlee.info\/blog\/?p=101"},"modified":"2005-02-09T09:48:18","modified_gmt":"2005-02-09T07:48:18","slug":"programming-as-an-activist-skill","status":"publish","type":"post","link":"https:\/\/www.ericlee.info\/blog\/programming-as-an-activist-skill\/","title":{"rendered":"Programming as an activist skill"},"content":{"rendered":"<p>Long before there was <a href=\"http:\/\/www.labourstart.org\">LabourStart<\/a>, long before unions were using the Internet, I was a computer programmer.  I worked in a worker-owned and democratically-run <a href=\"http:\/\/www.teldor.com\">wire and cable factory<\/a>, and my job was to maintain the computerized information systems.  I learned to program in a language called RPG which was used on IBM computers.<br \/>\nThe skills I learned then have proven to be of great use to me now, as an Internet activist working with unions around the world.  I think the time has come for unions to begin to understand that programmers can play a vital role in our organizing and communications strategies.<br \/>\nThese days I no longer program in RPG and haven&#8217;t seen an IBM mini-computer for years.  Most of my programming these days is done in a language called <a href=\"http:\/\/www.perl.com\/\">Perl<\/a>, which is one of the two or three most popular languages for writing Web-based applications.<br \/>\nMany trade union webmasters have learned <a href=\"http:\/\/www.w3c.org\/MarkUp\/Guide\/\">HTML<\/a>, which is the language that web pages are written in, and many have learned how to use tools like DreamWeaver or FrontPage to write the HTML for them, but very few have learned a proper programming language.<br \/>\nWhy should they?<\/p>\n<p><!--more--><br \/>\nBecause these languages &#8212; and the most popular would probably be Perl, <a href=\"http:\/\/www.php.net\/\">PHP<\/a> and <a href=\"http:\/\/www.python.org\/\">Python<\/a> &#8212; allow you to do things that ordinary web page design doesn&#8217;t allow.<br \/>\nBy using such languages, you can tremendously expand the effectiveness of your website.<br \/>\nLet me explain by example.<br \/>\nI was working on a website of an international organization that has affiliates in many countries.  It wants to list on its website all the affiliates, by country, in alphabetical order, with their website addresses and email addresses.  The last two have to be links, so that you can just click on the name of the affiliate and visit their website, or click on their email address to automatically send a message to them.  And the list changes every few weeks.<br \/>\nUsing Perl, I was able to write a very simple script to read through a text file with all the information, sorting it and formatting it as web page.  No one on the organization&#8217;s staff needs to know any HTML at all &#8212; my Perl script handles all that.  All they need to do is to keep their text list up to date.<br \/>\nThat&#8217;s a very small and simple example, but I think you get the idea.<br \/>\nIf you look at LabourStart, you&#8217;ll see an increasing number of interactive components to the website.  There are the <a href=\"http:\/\/www.labourstart.org\/lnw.shtml\">labour newswires<\/a>, which generate syndicated content automatically, every few minutes, in different formats (<a href=\"http:\/\/en.wikipedia.org\/wiki\/Javascript\">JavaScript<\/a> and <a href=\"http:\/\/www.webreference.com\/authoring\/languages\/xml\/rss\/intro\/\">RSS<\/a>).  All that is done using Perl scripts.<br \/>\nThere&#8217;s a directory of all the websites using those newswires, and a sub-directory of those which use only the new <a href=\"http:\/\/www.labourstart.org\/hswire\">health and safety newswire<\/a>.  That too was written entirely in Perl.<br \/>\nOf course the entire back-end of the website, the giant news links database with its thousands of records in 19 languages, submitted by over 300 volunteer corresponents, is entirely coded in Perl.<br \/>\nSo is the whole campaigning system &#8212; the generation of HTML web pages with online forms, the sending of protest messages, the counter tracking the success of a campaign &#8212; all of these are interactive scripts, written in Perl.<br \/>\nOkay, so I&#8217;ve got you convinced.  Unions can make great use of languages like Perl, PHP or Python to get their websites to do a lot more than simply display some web pages.  But there is a downside.<br \/>\nA few years ago, I suggested to a union that they make some changes to their site, which was using Perl scripts.  They asked their web design company, and were told that it would cost $1,500 a day to get a Perl programmer to work on the project.  I was later told that this was the going market rate in Britain.<br \/>\nBut Perl isn&#8217;t rocket science; if you have a programming background, or if you just take the time and effort, you can teach yourself.  I taught myself, mostly using Elizabeth Castro&#8217;s terrific little book, <a href=\"http:\/\/www.powells.com\/cgi-bin\/partner?partner_id=23921&#038;cgi=product&#038;isbn=0201735687\">&#8220;Perl and CGI for the World Wide Web&#8221;<\/a>.  (A dog-eared copy is always within reach of my computer.)  And you learn by example; you download Perl scripts that are readily available and you modify them to suit your union&#8217;s needs.  One good source is <a href=\"http:\/\/cgi.resourceindex.com\/\">here<\/a>.<br \/>\nPerl, PHP and Python should be taught at union education centers to those webmasters who&#8217;ve already learned HTML and want to know more.  Those of us who program in these languages should make some of our better scripts available to other unions.  For example, LabourStart uses <a href=\"http:\/\/www.labourstart.org\/cgi-bin\/stats\/show.cgi?lang=ts\">a lovely little script<\/a> to count visitors to our various home pages, to show them visiting in real time, and even to show which websites they came from.  A script like that could be a great alternative to the counters we often see on the bottom of union websites.<br \/>\nNow that unions have been using the web for a decade or more, it is time to upgrade the skills of union webmasters, to become less reliant on outside contractors (especially at the rate of $1,500 a day), and to learn to use the very best tools ourselves.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Long before there was LabourStart, long before unions were using the Internet, I was a computer programmer. I worked in a worker-owned and democratically-run wire and cable factory, and my job was to maintain the&#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[18],"tags":[],"class_list":["post-101","post","type-post","status-publish","format-standard","hentry","category-industrial-worker"],"_links":{"self":[{"href":"https:\/\/www.ericlee.info\/blog\/wp-json\/wp\/v2\/posts\/101","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.ericlee.info\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.ericlee.info\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.ericlee.info\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.ericlee.info\/blog\/wp-json\/wp\/v2\/comments?post=101"}],"version-history":[{"count":0,"href":"https:\/\/www.ericlee.info\/blog\/wp-json\/wp\/v2\/posts\/101\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.ericlee.info\/blog\/wp-json\/wp\/v2\/media?parent=101"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.ericlee.info\/blog\/wp-json\/wp\/v2\/categories?post=101"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.ericlee.info\/blog\/wp-json\/wp\/v2\/tags?post=101"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}