WordPress 2.0

Uncategorized — Titus Barik on December 28, 2005 at 9:52 pm

The web site has been upgraded to Word Press 2.0. In addition to an upgrade to PHP 5.1.1, most of the actual WordPress changes have occurred under the hood. Do expect some minor hiccups in the next few days, as we will be moving to a new server with SSL support.

Getting the Script’s Path with WSH

Uncategorized — Titus Barik on December 28, 2005 at 5:56 pm

WSH has no function or method for retrieving a script’s path, so in VBScript you can use the ScriptFullName property of the WScript object to extract the path, as shown here:

Function GetPath
    ' Retrieve path to the script file.
    Dim path
    path = WScript.ScriptFullName  ' Script filename
    GetPath = Left(path, InStrRev(path, "\"))
End Function

This function assumes that the path ends with a backslash character. But as long as Microsoft implements GetParentFolderName correctly, you get the path more portably with:

Dim fso
Set fso = CreateObject("Scripting.FileSystemObject")
Path = fso.GetParentFolderName(WScript.ScriptFullName)

From Windows Script Host 2.0 Developer’s Guide by Gunter Born.

Published in PHP Architect

Uncategorized — Titus Barik on December 25, 2005 at 1:23 pm

My article, “An Introduction to Drupal: A Modular Framework for Content Management“, has just been published in the December 2005 issue (Vol. 5 Issue 12) of PHP Architect. PHP Architect is a monthly magazine dedicated exclusively to professionals who use PHP as part of their everyday work. The publication is welcome news at the conclusion of this very busy year.

For more information, see the PHP Architect December 2005 Issue announcement, as well as the Drupal article annoucement on the Drupal site itself. Reprints are available electronically on a limited basis upon request.

Errata: Figure 7 is missing from the article. It can be downloaded here or in the PHP Architect forums.

Multiplayer Neverwinter Nights on Local LAN

Uncategorized — Titus Barik on December 24, 2005 at 7:15 pm

Neverwinter Nights requires each player in a local LAN game to own a copy of the game, if any of the clients have external Internet access. This requirement seems a little unreasonable for casual gaming. Luckily, a simple solution exists under Windows to disable server authentication. Simply edit the file:

%windir%\system32\drivers\etc\hosts

and add the following lines to remap the Neverwinter Nights official servers to localhost:

127.0.0.1       nwmaster.bioware.com
127.0.0.1       nwnauth.kr.infogrames.com
127.0.0.1       66.244.193.142
127.0.0.1       203.239.47.115

Happy gaming!

Discover Music With Pandora

Uncategorized — Titus Barik on December 16, 2005 at 9:36 pm

Pandora is a different kind of streaming music radio station. Unlike other services that offer recommendations based on similar purchases made by other users, Pandora uses the idea of a Music Genome to tag songs into distinct categories:

We ended up assembling literally hundreds of musical attributes or “genes” into a very large Music Genome. Taken together these genes capture the unique and magical musical identity of a song - everything from melody, harmony and rhythm, to instrumentation, orchestration, arrangement, lyrics, and of course the rich world of singing and vocal harmony.

An article on the Wall Street Journal on Unraveling Music’s DNA has more details:

Visitors to Pandora’s Web site are greeted with an invitation to enter the names of a few songs or artists they like. Pandora then generates a customized “radio station” that plays other songs it believes users will like, based on its scientific analysis. Users can click a tab to find out why Pandora has recommended a particular song — in the case of the Pink Floyd tune, Pandora says it is similar to “Come Together” in that it has “mild rhythmic syncopation, minor key tonality, repetitive melodic phrasing, extensive vamping and vocal harmonies.”

The interface is simple to use, with no additional software or plugin requirements other than Macromedia Flash. After some investigation, I discovered that the interface is actually built on the open source OpenLaszlo project, a platform that allows developers to create applications with the rich user interface capabilities of desktop client software and the instantaneous no-download Web deployment of HTML. The OpenLaszlo SDK consists of a compiler written in Java, a runtime JavaScript library, and an optional Java servlet that provides additional services to the running application.

An advertisement-supported version of Pandora is usable for free. A full, unlimited one-year subscription costs a mere price of $36 dollars a year. I’ve already paid for a one year subscription, so if you have any questions, feel free to ask.

Digg is the New Slashdot

Uncategorized — Titus Barik on December 11, 2005 at 9:05 pm

I’m sorry to say it, but it’s true: Slashdot is useless. Once my primary source of cutting-edge technology news, Slashdot has degraded in quality immensely in recent months. Slashdot has always had an open bias, but as of late, the bias has been so blatant that topics are rarely evaluated on merit anymore. Folks, believe it or not, open source is not always the answer to everything.

When Slashdot was just a hobbyist site, these faults were easily excusable. All of us are well aware of the extra burden involved in maintaining a site in addition to a 40 hour a week career. But for the editors running Slashdot, this isn’t a hobby anymore. This is their full-time job. The paid editors have done a terrible, terrible job of filtering and proof reading articles before publishing them.

Still, I stuck around, mainly because there was no equivalent that gave me the information I needed. But with the introduction of Digg, that has changed. Digg brings you up to date information with a modern, easy to navigate Web 2.0 inferface. Popular articles are determined by the users themselves, side-stepping the editor process entirely. And what I really like about Digg is that it provides a “blog this” feature which supports all major blog publishing software packages.

I do worry that as Digg expands, it will begin to experience many of the same issues that Slashdot faces today. But I think I’ll worry about that when it happens. Until then, farewell Slashdot.

iFIX Training

Career — Titus Barik on December 9, 2005 at 5:47 pm

I spent the better part of the week at a hotel in Duluth, Georgia, while attending GE iFIX Training with co-workers. iFIX is a Process and Hybrid Manufacturing application that offers scan based operation, ideally suited to applications requiring consistent performance and known response times. It is similar to applications like Rockwell RSView, and Wonderware InTouch. HMI and SCADA applications are typically industry specific, and are generally only found in control automation applications that interface with industrial PLCs. It was a good experience, and gave me a good impression of what can and cannot be easily accomplished in current HMI applications. I intend on attending a similarly structured course on GE Fanuc PLC ladder logic in the months to come.

titus@barik.net | The Weblog of Titus Barik