Code Diff

An Interview

I have a Facebook friend who is an elementary school teacher. One of their students is an aspiring web designer, and has some questions for me to answer.

  1. Does a website usually succeed?

    A website has to be made with a goal in mind before anything can be described as successful or not. The goal has to be something real and measurable. The kinds of websites I work on are made as part of greater business plans.

    Some people want to make interesting content that gets people to come to the site, and then make money by selling advertising space. This advertising has to be presented in a way that the people who buy the advertising can track what people do with the ads, like click on the ads, or only looking at the ads.

    Others people make sites that are advertisements in their own right. They make a website that serves to advertise for things they sell or do for their work.

    I think most websites are made with overly ambitious goals, like “world domination” or “making something cool”, but without a concrete means of making money off of it. I don’t want to call out any particular websites, so I’ll describe what I see is an annoying sign of that lack of focus: sites with so many ads that it’s hard to tell what’s the real content on the site.

  2. Do people usually make game or informational websites?

    Most websites are informational and not game-y. Examples are news sites, blogs, encyclopedias, video hosts, or let people write review sites, ask questions, or post want ads for jobs. Or they make websites that sell things, like what Amazon and Craigslist does.

    Even though the Web has been around over decades, the technology for having a full-on web game still isn’t mature or secure to do anything super ambitious. Most games that run over the Internet work over standalone programs or phone apps, like your World of Warcraft, or your Candy Crush Saga.

  3. How long does it usually take to learn code?

    It takes a lot longer than those course that promise you to learn how to code in 21 days or whatever. Programming takes a mindset that can trace through possibilities, and work out all the consequences of an action. Programming is like describing how to do something to a simple-minded person who has to be told exactly how to do something in a language they can understand.

    Learning how to do this takes a couple of years of practice, and you learn how to break down activities into smaller steps that can be described, and to realize how decisions made early in a program will play out over the process you want to enact. I’ve been a professional coder for almost 10 years, and I still pick up new things every week, so you’re never going to stop learning.

  4. What is the best way to make a web site?

    Since my work involves making websites for other people, it’s best to know exactly what they want out of their website before our artist works out the design. The process starts by writing out exactly what kind of pages are going to be in the website, how they will work, and how users are presented all the information available. Once every detail gets worked out, along with a schedule of what gets finished when, I start programming for it, starting with a ready-made website “kit” that I help to customize and look like what the customer wants.

  5. How many days a week do you work?

    I work the traditional 9–5, Monday through Friday.

    I have worked on some side projects as a freelancer, and that I do when I’m not working my day job, but it’s not often.

  6. What kind of code do you prefer and why?

    I like working on what’s called “backend” code. A website has many parts, each written in their own language, like HTML, JavaScript, and CSS. What you get in a web browser or even a web app is driven by another computer that serves the content to the user, and I work on code that runs there. The language I prefer to work in for those jobs is called PHP. It’s not a “pretty” language, but it’s where the work is.

  7. What do you use to create a website?

    I use a collection of programs that I’ve made work together which I run on my laptop. I use a text editor that I’ve been using for over 20 years, and a collection of other tools that I’ve configured to work well with it. These help me catch errors in my code and track my progress as I go. My laptop runs a mini webserver on it that lets me create and test websites out of the way of the prying eyes of the public.

Jumping on the gulp.js bandwagon

For funzies and learnzies, I reworked my Normalize.css Sass fork to use gulp.js instead of the iconoclastic mix of shell scripts and a Makefile.

I had been going with my batches of shell scripts because I value auditability in what I use, and to keep a low overhead of 3rd-party dependencies. Every additional programming language and its homegrown package manager that I add kills me a little inside.

But what won me over with gulp is that the Node.JS module ecosystem has been focused on front-end development problems. In spite of the high package overhead involved with installing gulp and all its companion packages—meaning, screens of other package install messages go flying by for every final package I explicitly install—it’s all self-contained. And I get to benefit from other peoples’ work in scratching the same itches that I have.

Things that I miss in the Doctor Who reboot

As Doctor Who enters its 8th season, there are aspects of the old show that weren’t carried over to the reboot:

Explicit TARDIS hum

The reboot has subtle ambient sounds, witness:

Do you recognize that sound from the reboot? Maybe if you listen with noise canceling headphones on. The old series had the following, mixed so it was noticeable, but didn’t interfere with dialog:

Companions having their own rooms in the Tardis

I admit that this was something introduced during the John Nathan Turner era, but with the budget given to the new reboot, I’d expect this kind of thing.

Missing Documentation

I had to help a client with a WooCommerce problem with product catalog theme overrides.

I have some things to add to their page on Template Structure + overriding templates via a theme:

  • The resulting rendered theme files loaded by default are not the same as what would be loaded if you copy over the included files from their templates directory.
  • If a page like content-single-product.php gets overridden by a local version, then single-product.php needs to be copied over as well. This ate up a lot of time trying to diagnose, and I had to trace through the WooCommerce source code to even get a hint that I had to do this.
  • There is no equivalent of WordPress’ Template Hierarchy page made for WooCommerce templates.

Well I love life

Sometimes you merely have to look at what ideas each side in a battle supports. I’m not going to tell you what to decide, only what’s at stake. It is explicitly a battle of those on the side of life vs. those on the side of death.

As someone who loves life, this credo of the Islamist totalitarians scares me to the core: http://www.mrc.org/articles/times-omits-hasans-chilling-we-love-death-more-you-love-life