///////////////////////////////////////////////////////////////////////
// Originally written by Phil Puddick (2003) in Emacs on Red Hat 7.3 //
///////////////////////////////////////////////////////////////////////

//Pop up style windows will always open in the middle of the users screen
function NewWindow(mypage,myname,w,h,scroll, size)
{
	LeftPosition = (screen.width) ? (screen.width-w)/2 : 0;
	TopPosition = (screen.height) ? (screen.height-h)/2 : 0;
	settings =
	'height='+h+',width='+w+',top='+TopPosition+',left='+LeftPosition+',scrollbars='+scroll+',resizable="+size+'
	win = window.open(mypage,myname,settings)
}

//Add bookmark
var bookmarkurl="http://www.alpharepro.co.uk"
var bookmarktitle="Alpha Reprographics - Photocopier Solutions for the UK"

function addbookmark(){
if (document.all)
window.external.AddFavorite(bookmarkurl,bookmarktitle)
}


// JavaScript Document
//Allowing for the opening up of new windows from a menu_array.  Much thanks goes to Adios - the digruntled postal worker - from the
//javascript help forums at www.sitepoint.com for getting this script to work
var X_win = null;
////////////////////////////////
var w = 810; // window width ///
var h = 510; // window height //
////////////////////////////////
var l = (screen.availWidth - w - 20) * .5;
var t = (screen.availHeight - h - 35) * .5;
var r = 0; //Not resizable
var s = 0; // Toolbars are present


function open_X_win(url)
{
	X_win = open(url,'X_win','width='+w+',height='+h+',left='+l+',top='+t+',status,scrollbars='+s+',resizable='+r+'');
	if (X_win && !X_win.closed)     
		X_win.focus();
	return false;
}


///////////////////////////////////////////////////////////////////////
// Last updated on 17/04/07 on Emacs on Edgy Eft by Philip Puddick   //
///////////////////////////////////////////////////////////////////////
