try another color:

try another fontsize: tiny small normal big huge
netsperience 2.x
Drupal web development and other stuff

Welcome to netsperience 2.x

This is the personal web site of Randall Goya aka decibel.places dba netsperience

I develop community, social publishing, semantic publishing, ecommerce and rich media Web 2.x web sites (beyond "Web 2.0"). I also optimize web sites for SEO and SMO. I build most of my projects with Drupal, PHP, MySQL, HTML, CSS & jQuery.

Here you can view my professional portfolio, read my blog, listen to some tunes by me, or on the Jango Juke BoxI'm also on Facebook & twitter & LinkedIn - View the netsperience company profile on LinkedIn.

You're probably wondering, "If this is netsperience 2.x, what happened to netsperience 1.0?" It was at GeoCities Free Hosting for over ten years, but now it's gone along with the rest of GeoCities - you can still view much of the old GeoCities site at ReoCities

When Comments Go Unmoderated...

I came across this web page, looking for something else, that has an insane list of 51 unmoderated comments. The first one is relevant to the original post, and the following 50 are spam. After gay men with gay men it went downhill from there.

A Selection from the Beginning:                                       1st 10% of page:            

The page was so huge - about 6K px wide (because of text overflow) by > 250K px tall - that online screen capture apps choked.

I tried DuckLink (a Windows app) to capture the full page, but it choked at about 8%.

The 10% capture was provided by - although it is beyond the normal capability of the free online service, the owner tried to grab it for me. But he must have misread the height: I said the page is over 250K px tall, and he only captured the first 25K px.


Connect Drupal to Multiple Remote Databases via SSH Tunnel

I'm working on a Drupal application that stores data in separate mysql databases, and updates them frequently from Salesforce via nodejs scripts run through Lucene and CouchDB.

The extra mysql dbs are 16+ GB and it's not practical nor necessary to keep them locally since I only want to read the latest data in local development.

Wouldn't it be cool if my local development Drupal sites can read from the remote database servers?

In some cases you can just use the connection you find in the remote site's settings.php:

'otherdb' => 'mysqli://username:password@hostname/dbname'

(note: it's a Drupal 6 site so that's why you don't see an array - I will give a Drupal 7 example below)

However, there's often a twist: I must create a SSH tunnel to connect to this particular db server.

First, you need to have configured and installed SSH keys on your local and remote machines.

Then fire up your terminal and create the SSH tunnel to forward the remote mysql port to a local port. Keep this connection alive as long as you need to connect to the remote database. (This technique is based on information clearly presented by Engine Yard)

ssh -L [local port]:[database host]:[remote port] [ssh-username]@[remote host]
IMPORTANT: use a different port for your tunnel [local port] than the one you normally use for mysql; for example, if you connect to mysql locally on the default port 3306, use 3307 (or any other unused port) for your tunnel. You should use the correct [remote port] which is typically 3306, and you can see if it is different by looking at settings.php in the remote site.
ssh -L 3307:[database host]:3306 [ssh-username]@[remote host]
Then you can test your connection (in a different terminal instance):
mysql -u[dbuser] -p -P 3307 -h
Here is the connection in settings.php for Drupal 6:
'otherdb' => 'mysqli://username:password@'
What's cool is that you can mix local and remote databases. For example, I want to use a local copy of the Drupal database, which is smaller and easier to sync, and read the data from the second (and third, in my case) remote dbs.
$db_url = array(
  'default' => 'mysqli://local-dbuser:password@localhost/local-dbname',
  'otherdb' => 'mysqli://username:password@',
  'otherdb2' => 'mysqli://username:password@'
You can also connect Drupal to the default remote database, but it makes sense to use a local instance for development.
And in Drupal 7:
$databases['default']['default'] = array(
  'driver' => 'mysql',
  'database' => 'local-dbname',
  'username' => 'local-dbuser',
  'password' => 'password',
  'host' => 'localhost',
  'prefix' => '',
$databases['otherdb']['default'] = array(
  'driver' => 'mysql',
  'database' => 'dbname',
  'username' => 'username',
  'password' => 'password',
  'host' => '',
  'port' => '3307',
  'prefix' => '',


If the db user for the remote db has all privileges, your application may alter the remote database.
Therefore, you should create a "read-only" user for the remote database which will prevent you from altering it.

Errors and Inconsistencies on LinkedIn

I have great respect for the pool of experts and talent who are members of LinkedIn.

However, I find the LinkedIn interface clumsy, cumbersome, and often, wrong.

Here is a collection of errors and inconsistencies from LinkedIn.

Can't congratulate Keith on new job:

My friend Keith Williams announced his role as Chief Technology Architect at Monimus, but I could not congratulate him:

Drupal 7 Migrate V2 and Addressfield: SOLVED!

I had to migrate site members from a legacy site with an Oracle db to a relaunch on Drupal 7. Instead of connecting directly to Oracle, I was provided with an Excel dump which I converted to csv. Also the old site does not require members to be authenticated, so I did not have to deal with old passwords.

There are a lot of stale posts in Google results about migrating Addressfield that do not work on the latest Migrate V2 for Drupal 7. For one thing arguments in the field mapping are deprecated.

Using the Migrate module I was able to create migration classes for the users, and some other information; but I got stuck at importing the address data into the Drupal Addressfield table, because it uses subfields and requires building an array in Migrate.

I used colon notation for subfield mapping, but it was not working.

->addFieldMapping('body', 'body');
$this->addFieldMapping('body:summary', 'excerpt');

Migrate kept throwing an error: Call to a member function import() on a non-object

But when I put drush_print_r on the line throwing the error, I could see the stdClass object arrays were there and populated with the correct data.

I decided to abandon the Addressfield migrate class and use db_insert in an existing class (class SchoolMigration) where I was already running db queries.

It worked, and although I was worried a direct db_insert would not roll back, since I registered the inserts in the process() function for class SchoolMigration, they also rolled back.

Building a Video Playlist for JW Player 6 with Drupal 7 Views

I took over a Drupal 7 project building a web application for college students to upload original videos about their school, and for schools to manage, group, and share the videos.

It's a startup privately funded by the principal, and we are literally working on a shoestring. My previous experience with media in Drupal led the principal to contact me via LinkedIn.

When it came time to build a video playlist in Drupal Views for JW Player version="6.7.4071" (formerly known as Longtail Video), I found very little useful documentation. In fact, someone suggested that those who know how are not interested in sharing their knowlege. -- but not me smiley

There are a couple of videos on YouTube by Bryan Ollendyke for Drupal 6. But a lot has changed in Drupal since then.

The Goal:

Back to the playlist: Site admins can mark a video featured by ticking a checkbox on the custom video content type. Now I want to display those featured videos as a playlist.


JW Player provides clear documentation about how to embed the player, and how to construct and load the playlist via a RSS feed.

The structure of the RSS file:

<rss version="2.0" xmlns:jwplayer="">

    <title>Sintel Trailer</title>
    <description>Sintel is a fantasy CGI from the Blender Open Movie Project.</description>
    <jwplayer:source file="/assets/sintel.mp4" />


There are various threads on discussing video playlists for JW Player. None of them were particularly useful for me.

Syndicate content