January’s Program: Star Probe

Writing: 01/26/16 at 22:44:40 MDT by SafePit

Writing Star Probe, 1984Wow, 2016 and I'm still digging programs out of my stack of print outs. Kicking off the new year, I'm grabbing a story based program. I wrote Star Probe, our program of the month, in the style of a Chose Your Own Adventure book—and yes, I actually owned most of them. Although you can only enter numbers, Star Probe is actually an example of interactive fiction. Though not as advanced as an Infocom game, Star Probe delivers an interesting, if short, story to the player. Before I spoil where I drew my inspiration, go play it. It will only take a few minutes. Just try to ignore the horrible grammar and spelling of a 14-year-old.

You can read more of this article or head on over to my ZX81 site to catch up on past programs of the month. [ View Article ]

Printer Friendly version - January’s Program: Star Probe  Send to a Friend   (24 reads) [ 0 comments ]

Tags: adventure  basic  fiction  game  if  if  input  interactive  january  monthly  print  probe  programming  star  star probe  story  zx81 

Favoring Icons

Internet: 01/12/16 at 20:20:37 MDT by SafePit

Internet I’m slowing working through updating my site. Recently, I decided to update my icons. I’ve been using favorite icons for years—favicon.ico for those that care. But, it was old and boring. Time to update.

The world has progressed a bit though. At the dawn of App stores, web sites could add icons to those pristine phone and tablet pages. Those tiny little icons became passé. Fortunately, on this site at least, I had added one of those touch icons. It worked at the time. But, again, things changed.

With the advent of retina displays, you now need a couple of different versions of different shapes, sizes and what not. Of course, it wasn't just mobile devices. Computers and their browsers got more sophisticated as well. They too started to grab those icons and, well, things just look weird now without them.

In fact, it was Safari that I first noticed that all my pretty icons looked dull. Time to get cracking! I found some pictures and used Canva to build a nice image—was easier than cracking open Gimp. I now have a pretty icon, but now what? Crud, all those different sizes and such are just going to be a pain to generate. Or will they?

I'm off to my favorite search engine to search for what I need. I started digging around specifications of various companies, Apple being one of the first since that was my problem. After an hour of that, I finally landed on a favorite icon generator. “Nice!” I said. Time to plug and chug, and, voilà, I had a set of icons on my site. Sort of.

Although it worked, it was only a limited subset and things didn't quite update right. Then, come to find out, my favorite icon didn't work. Not to mention it was a subset of applications which left me with a less than stellar experience.

Time to search some more. I ran across a forum post on my favorite icon problem and, surprise, had a link to their icon generator. Unlike my first attempt, this was a one stop shop of perfection. It was almost overwhelming, but ended up exactly what I needed.

This brings me to today. I now have a nice set of icons for my main site. Not quite sure if I’m entirely happy with it, but it is much better than the old and feels, well, better. I’ll give it a week. Until then, let me know your own experiences in the comments. [ View Article ]

Printer Friendly version - Favoring Icons  Send to a Friend   (55 reads) [ 0 comments ]

Tags: favicon  generator  icon 

Slugging it out with SEO

News: 01/02/16 at 00:40:40 MDT by SafePit

News I’m trying to start of the new year by updating all my web sites. I’ve been researching SEO (search engine optimization) for a few months, but only recently started to work through how to actually do it. The last few days have been a eureka moment for me.

The first problem I had to deal with was how to hide the index script. Generally if you are using Apache you can do this with an .htaccess file. For my CMS, this directive worked reasonable well:
DirectoryIndex cgi-bin/index.cgi
Unfortunately, it isn’t perfect and I had to do a lot of hacking in the WebAPP code to get to work. I really want to clean up the CMS code anyway, so I started to rewrite it using my test site. But I needed a template to start from. Fortunately, I’d also been playing around with WordPress to see how it deals with slugs.

In researching and viewing how WordPress does things, I ran across this great article. It walks through each line of WordPress’ .htaccess file, which wasn’t too hard to understand. The real gem, though, was the last line that discussed how it read the slug. WordPress uses the REQUEST_URI variable instead of the normal QUERY_STRING.

With this missing piece of the puzzle now in place, I was able to actually to modify my .htaccess file. Obviously I needed to use CGI instead of PHP, since my CMS is Perl based. But outside of that, it is identical to WordPress’s.

The real magic then happened in the script itself. Using the REQUEST_URI was pretty easy, once I figured out a few bugs in the CMS. As an example, here is some simplistic router code. It isn’t the cleanest yet, but it works.
# Get slug
$raction = $ENV{REQUEST_URI} || '/'; # get slug
$raction =~ s/\/+/\//g; # reduce all slashes to a single one
# Display default page
if ($raction eq '/') {
# Display news article
elsif ($raction =~ /^\/(\d+)/) {
$info{'id'} = $1; # pull article ID from slug
require "$sourcedir/topics.pl"; # grab article functions

Note that the slug right now is just the article ID as that is how the existing code finds the article. It isn’t the most friendly, but it does work. In fact, I could leave it if I really wanted to. I haven’t decided yet how to actually define the slugs. WordPress, by default, uses a date with title system like this: /2016/01/01/slugging-it-out/. Some articles say don’t do the date thing and just use: /slugging-it-out/.

I’ve seen other sites that leave the ID and add the title to end like so: /244/slugging-it-out/. I discovered that Google uses a hash after the ID on some of its pages to make it obvious: /244#slugging-it-out/. In fact, my code as written above will allow either of these options to work. The web seems divided on if either of these are good ideas so I may just need to make a choice and move on.

And there you have it. I’ve now built about a dozen slug routes on my test site. Things seem to work pretty well, but I had to hack a lot of my internal code to ensure they print the slugs and not the query strings. For now, I’ve also set up my router to allow either format. In fact, for some internal facing routines I may not even bother. If WordPress doesn’t, why should I?
View Article ]

Printer Friendly version - Slugging it out with SEO  Send to a Friend   (80 reads) [ 0 comments ]

December’s Program: Monkey Maze

Programming: 12/29/15 at 14:03:21 MDT by SafePit

Programming Monkey Maze, 1983Time to close out the year with another classic remaking. Back in 1983, I decided to try my hand at recreating Nintendo’s fan favorite: Donkey Kong. My version, cryptically called Monkey Maze, is December’s Program of the Month. Not quite as complex as the original, my version has only a single board that you can navigate around using the ZX81 cursor keys (5, 6, 7 and 8 which map to left, down, up and right). It plays pretty well. Go give it a try, and avoid the barrels, if you can.

You can read more of this article or head on over to my ZX81 site to catch up on past programs of the month. [ View Article ]

Printer Friendly version - December’s Program: Monkey Maze  Send to a Friend   (76 reads) [ 0 comments ]

Tags: arcade  classic  december  donkey kong  game  maze  monkey  monkey maze  monthly  programming  video  zx81 

NaNoWriMo 2015: Winner!

Writing: 11/30/15 at 22:10:45 MDT by SafePit

Writing Well, last day of NaNoWriMo 2015. I validated 53,422 words for the win. I actually hit 50K just before Thanksgiving. It was nice staying on track this month which prevented the sprint I needed to do last year.

Unfortunately, I'm not done. I wrote about 53 scenes and have the outline for another 41. But those 41 will probably balloon a bit as they get fleshed out. I'm not complaining. The story is coming along and I'm feeling good about where its going.

More to come!

View Article ]

Printer Friendly version - NaNoWriMo 2015: Winner!  Send to a Friend   (101 reads) [ 0 comments ]

Tags: book  NaNoWriMo  novel  steel series  Steel Strong  winner  writing 

November’s Program: Dragon’s Lair

Programming: 11/29/15 at 14:49:11 MDT by SafePit

Programming Dragon’s Lair, 1985One of my favorite video games as a kid was a rather unlikely one. It wasn’t the coolest graphics or excellent control. It was about story and animation. It was, of course, Dragon’s Lair. The odd laser disc game by famed animator Don Bluth. Not surprisingly, I tried to recreate a bit of the game's feel on my ZX81. My attempt is, of course, November’s Program of the Month.

You can read more of this article or head on over to my ZX81 site to catch up on past programs of the month. [ View Article ]

Printer Friendly version - November’s Program: Dragon’s Lair  Send to a Friend   (113 reads) [ 0 comments ]

Tags: animation  arcade  disc  Don Bluth  dragon  dragon's  lair  laser  monthly  november  programming  zx81 

October's Program: The Haunting

Writing: 10/31/15 at 21:05:43 MDT by SafePit

Writing THE HAUNTING, 1985It is Halloween and October’s Program of the Month is right on time. When I pulled listing for The Haunting from my stack I knew it would be perfect. Although short, I knew I’d be challenged as this program of the month requires something I hadn’t needed before. That something was sound.

You can read more of this article or head on over to my ZX81 site to catch up on past programs of the month. [ View Article ]

Printer Friendly version - October's Program: The Haunting  Send to a Friend   (120 reads) [ 0 comments ]

Tags: cassette  fast  haunting  monthly  music  note  numeric  oscillate  plug  programming  slow  string  tape  ula  zx81 

September's Program: Input Two

Writing: 09/20/15 at 23:04:10 MDT by SafePit

Writing Input Two, 1984To my surprise, I was thumbing through my old printouts and discover that I actually wrote an Input Two program. I covered Input One as March’s Program of the Month. For September, however, it is Input Two’s opportunity to shine.

You can read more of this article or head on over to my ZX81 site to catch up on past programs of the month. [ View Article ]

Printer Friendly version - September's Program: Input Two  Send to a Friend   (194 reads) [ 0 comments ]

Tags: dim  dimension  input  monthly  programming  two  zx81 

August's Program: Canyon Raider

Programming: 08/22/15 at 00:13:28 MDT by SafePit

Programming CANYON RADIER, 1983While reading through my old programming notebook last month, I wondered about using them on my website. From my earliest programming days, the notebook has a number of programs that never made it to my stack of printouts. Canyon Raider, August’s program of the month, is one of those programs.

You can read more of this article or head on over to my ZX81 site to catch up on past programs of the month. [ View Article ]

Printer Friendly version - August's Program: Canyon Raider  Send to a Friend   (235 reads) [ 0 comments ]

Tags: canyon  fuel  game  monthly  notebook  programming  raider  scroll  x81 

How to Build a Site - Again

News: 08/20/15 at 22:25:24 MDT by SafePit

News I've been using this theme and with the WebAPP CMS for a few years now. Unfortunately, it is getting a bit old in the tooth. Although mostly flat, which fits nicely with today's designs, it isn't responsive. In fact, the original mobile version of the site was for the Palm Pilot. Really?

So, I've started to dig in again. I'm looking to revamp the entire site. From internals to externals. The hope is to modernize and maximize the value of R4F as best as I can.

To that end, I've been digging around with Skeleton and have a test responsive template started. So far it doesn't look half bad. But, it can be better. Plus, I need to get it working with all the elements in the site. I'm digging into other CSS code to see what I can do and to better understand how to make things good.

I found a blog talking about SOE as well. That is actually useful. It is telling me what modern, and some not so modern, that I should be fixing to make my site work best.

I'll post more on all these ideas in the coming weeks. If you have a special topic, let me know.

Stay tuned! [ View Article ]

Printer Friendly version - How to Build a Site - Again  Send to a Friend   (240 reads) [ 0 comments ]

Tags: build  cms  css  custom  design  flat  responsive  soe  webapp 

Slide: 40029 Valentines Day Box

Main Menu



Other Sites


Who's Amung Us?
carbon neutral offers and shopping with kaufDA.de

Tag Cloud


 Remember Me?

Forgot password?
You are a guest user.
You can register for free by clicking here.