

var image1=new Image()
image1.src="chris_home.jpg"
var image2=new Image()
image2.src="cormac550D_home.jpg"
var image3=new Image()
image3.src="mic_holder_pop_home.jpg"
var image4=new Image()
image4.src="box_home.jpg"
var image5=new Image()
image5.src="camera_mics_home.jpg"


/*
 * Parent (iframe holder) postMessage 'receiving' javascript.
 * (If you want the complete postMessage code, see the links below.)
 *
 * Modified by Neal Delfeld.
 * Released under the Apache 2.0 license.
 *
 *
 * Other reference info:
 *
 * A backwards compatable implementation of postMessage.
 * By Josh Fraser (joshfraser.com, http://www.onlineaspect.com/2010/01/15/backwards-compatible-postmessage/)
 * Released under the Apache 2.0 license.
 *
 * This code was adapted from Ben Alman's jQuery postMessage code found at:
 * http://benalman.com/projects/jquery-postmessage-plugin/
 *
 * Other inspiration was taken from Luke Shepard's code for Facebook Connect:
 * http://github.com/facebook/connect-js/blob/master/src/core/xd.js
 *
 * The goal of this project was to make a backwards compatable version of postMessage
 * without having any dependency on jQuery or the FB Connect libraries.
 *
 * My goal was to keep this as terse as possible since my own purpose was to use this
 * as part of a distributed widget where filesize could be sensative.
 *
 */

/* everything is wrapped in the XD function to reduce namespace collisions */
var XD = function(){

    var interval_id,
    last_hash,
    cache_bust = 1,
    attached_callback,
    window = this;

    return {
        receiveMessage : function(callback, source_origin) {

            /* browser supports window.postMessage */
            if (window['postMessage']) {
                /*  bind the callback to the actual event associated with window.postMessage */
                if (callback) {
                    attached_callback = function(e) {
                        if ((typeof source_origin === 'string' && e.origin !== source_origin)
                        || (Object.prototype.toString.call(source_origin) === "[object Function]" && source_origin(e.origin) === !1)) {
                            return !1;
                        }
                        callback(e);
                    };
                }
                if (window['addEventListener']) {
                    window[callback ? 'addEventListener' : 'removeEventListener']('message', attached_callback, !1);
                } else {
                    window[callback ? 'attachEvent' : 'detachEvent']('onmessage', attached_callback);
                }
            } else {
                /* a polling loop is started & callback is called whenever the location.hash changes */
                interval_id && clearInterval(interval_id);
                interval_id = null;

                if (callback) {
                    interval_id = setInterval(function(){
                        var hash = document.location.hash,
                        re = /^#?\d+&/;
                        if (hash !== last_hash && re.test(hash)) {
                            last_hash = hash;
                            callback({data: hash.replace(re, '')});
                        }
                    }, 100);
                }
            }
        }
    };
}();

<!--
    function submitenter(myfield,e)     {
    var keycode;
    if (window.event) keycode = window.event.keyCode;
    else if (e) keycode = e.which;
    else return true;
    if (keycode == 13)
    {
    myfield.form.submit();
    return false;
    }
    else
    return true;
    }
//-->
function randomimagegen()
{images = new Array(6);

images[0] = "<img src='/headphone-guy.gif' valign=bottom>";

images[1] = "<img src='/headphone-girl.gif' valign=bottom>";

images[2] = "<img src='/gi-screwdriver.gif' valign=bottom>";

images[3] = "<img src='/mp3-girl.gif' valign=bottom>";

images[4] = "<img src='/mic-girl.gif' valign=bottom>";

images[5] = "<img src='/sound-guy.gif' valign=bottom>";

images[6] = "<img src='/chris_with_preamp.gif' valign=bottom>";
index = Math.floor(Math.random() * images.length);

document.write(images[index]);}


 function openimage(image,width,height,title)
 {if (image.indexOf(".jpg")>0){
tag = image.replace(/.jpg/,"")}
 else { if (image.indexOf(".gif")>0){
tag = image.replace(/.gif/,"")}}

scrollbar=0
if (height>700){
height=700
scrollbar=1
}
 imagewin = window.open ('',tag,"width="+width+",height="+height+",location=0,menubar=0,resizable=0,scrollbars="+scrollbar+",status=1,titlebar=1,toolbar=0,screenX=50%,left=50%,screenY=50%,top=50%");
var content =
imagewin.document.write(
'<html><head><title>'+title+'</title><meta http-equiv="imagetoolbar" content="no" /></head>'
+'<body><table height=100% width=100%><tr><td align=center valign=center colspan=2>'
+'<img src="/'+image+'"></td></tr>'
+'<tr height=5><td align=left><img src="/image-page-logo.gif"></td>'
+'<td align=right><br><FORM><INPUT TYPE=\'BUTTON\' VALUE=\'Close Window\' onClick=\'window.close()\'> </FORM></td></tr></table></body></html>')

}










