
function showHand(source) 
{
    source.style.cursor = 'pointer';
}

function showCursor(source) 
{
    source.style.cursor = 'auto';
}

function ChangeImageNET(source, fileName) {

    document.images[source].src = fileName;

   // document.images["ctl00_ContentPlaceHolder1_" + source].src = fileName;
}

function PlaySong(source, file, id, imageName) 
{
    //ChangeImageNET(id, imageName);
    ChangeImageNET(source, imageName);
    document.images[source].onmouseout = "";
    soundManager.play(source, file);
}

function PauseSong(source) 
{
    soundManager.pause(source);
}

function ResumeSong(source) 
{
    soundManager.resume(source);
}

function StopSong(source) 
{
    soundManager.stop(source);
}


function PlaySingle(source, fileName, playerWidth, playerHeight) {

    var so = new SWFObject('videoplayer/player.swf', 'ply', playerWidth, playerHeight, '9', '#ffffff');
    so.addParam('allowfullscreen', 'true');
    so.addParam('allowscriptaccess', 'always');
    so.addParam('wmode', 'opaque');
    so.addVariable('file', fileName);
    //so.addVariable('file', 'http://www.longtailvideo.com/jw/upload/bunny.mp3');
    so.addVariable('duration', '33');
    so.write(source);

}

function sendToStore(url) 
{
    window.open(url, 'openmicstore')
}



//function rotateImage() {

//    var path;
//    var begin;
//    var newImgNum;
//    var newRandNum;
//    var oldRandNum;
//    var imageNum;
//    var maxImg = 3;
//    do {
//        newRandNum = Math.round(Math.random() * (maxImg - 1)) + 1;
//    } while (oldRandNum == newRandNum);

//    if (newRandNum <= 9) { newImgNum = "0" + newRandNum; }
//    else { newImgNum = newRandNum; }

//    oldRandNum = newRandNum;


//    path = document.images['adsimage'].src;

//    begin = path.indexOf('/main_ad/');
//    begin = path.substr(begin + 16, 2);
//    imageNum = Number(begin.valueOf());
//    imageNum = imageNum + 1;

//    //this is count for total of active ads
//    if (imageNum > 3) {
//        imageNum = 1;
//    }

//    if (imageNum < 10) {
//        begin = "0" + imageNum;
//    }

//    document.images['adsimage'].src = "images/main_ad/adimage" + begin + ".jpg";


//    if (imageNum == 1) {
//        document.images['adsimage'].width = "75";
//        document.images['adsimage'].height = "107";
//        document.getElementById('imageLink').href = "http://www.webster.com";
//    }
//    else if (imageNum == 2) {
//        document.images['adsimage'].width = "75";
//        document.images['adsimage'].height = "214";
//        document.getElementById('imageLink').href = "http://www.jampact.org";

//    }
//    else if (imageNum == 3) {
//        document.images['adsimage'].width = "75";
//        document.images['adsimage'].height = "107";
//        document.getElementById('imageLink').href = "http://www.jampact.org/anniversary";
//    }

//    document.images['spacer'].src = "images/web/spacer.gif";

//}


//function rotateImageDefault() {

//    var path;
//    var begin;
//    var newImgNum;
//    var newRandNum;
//    var oldRandNum;
//    var imageNum;
//    var maxImg = 3;
//    do {
//        newRandNum = Math.round(Math.random() * (maxImg - 1)) + 1;
//    } while (oldRandNum == newRandNum);

//    if (newRandNum <= 9) { newImgNum = "0" + newRandNum; }
//    else { newImgNum = newRandNum; }

//    oldRandNum = newRandNum;


//    path = document.images['adsimageDefault'].src;

//    begin = path.indexOf('/main_ad/Default/');
//    begin = path.substr(begin + 31, 2);
//    imageNum = Number(begin.valueOf());
//    imageNum = imageNum + 1;

//    //this is count for total of active ads
//    if (imageNum > 2) {
//        imageNum = 1;
//    }

//    if (imageNum < 10) {
//        begin = "0" + imageNum;
//    }



//    document.images['adsimageDefault'].src = "images/main_ad/Default/adimageDefault" + begin + ".jpg";

//    if (imageNum == 1) {
//        document.images['adsimageDefault'].width = "100";
//        document.images['adsimageDefault'].height = "285";
//        document.getElementById('imageLinkDefault').href = "http://www.jampact.org/anniversary";
//    }
//    else if (imageNum == 2) {
//        document.images['adsimageDefault'].width = "100";
//        document.images['adsimageDefault'].height = "143";
//        document.getElementById('imageLinkDefault').href = "http://www.jampact.org";
//    }

//    document.images['spacerDefault'].src = "images/web/spacer.gif";

//}


//function setFirstAd() {
//    document.images['adsimage'].src = "images/main_ad/adimage02.jpg";
//    document.images['adsimage'].width = "75";
//    document.images['adsimage'].height = "214";
//    document.getElementById('imageLink').href = "http://www.jampact.org/anniversary";
//}

//function setFirstAdDefault() {
//    document.images['adsimageDefault'].src = "images/main_ad/Default/adimageDefault01.jpg";
//    document.images['adsimageDefault'].width = "100";
//    document.images['adsimageDefault'].height = "285";
//    document.getElementById('imageLinkDefault').href = "http://www.jampact.org/anniversary";
//}
