<?xml version="1.0"?>
<!-- index.html -->
<html>
	<head>
		<title>eMuseum</title>
		<script language="Javascript">
function clearNew()
{
	//clear the 'new' values which are used for page navigation
	// (this protects against problems occuring when the user clicks the
	// browser 'back' button)

	//&newvalues=1 flags the beginning of any 'new' state values that get set for navigation
	//Clear out any existing before setting.

	var i = document.frm.action.indexOf('&newvalues');
	if(i>0)
	{
		document.frm.action = document.frm.action.substr(0,i);
	}
}

function linksearch(profile, fieldname, fieldvalue, style, searchdesc)
{
	clearNew();
	document.frm.emu_action.value = 'searchrequest';

	//Build the URL-encoded search string
	document.frm.action += '&newvalues=1&rawsearch=' + fieldname + '/,/is/,/' + fieldvalue + '/,/false&newstyle=' + style + '&newprofile=' + profile + '&newsearchdesc=' + searchdesc + '&newcurrentrecord=1';
	document.frm.submit();
}

function singleview(newpage)
{
	clearNew();
  	document.frm.emu_action.value = 'newpage';
	document.frm.action += '&newvalues=1&newstyle=single&newcurrentrecord=' + newpage;
	document.frm.submit();
}

function submitpage(action,para)
{
	clearNew();
  	document.frm.emu_action.value = action;
  	var cS;
  	if (document.frm.action.indexOf("?")==-1){cS='?'}else{cS='&'}

	switch (action)
	{
	case 'newpage' :
		document.frm.action += cS + 'newvalues=1&newcurrentrecord=' + para;
	  	break
	case 'style' :
	  	document.frm.action += cS + 'newvalues=1&newstyle=' + para;
	  	break
	case 'sort' :
	  	document.frm.action += cS + 'newvalues=1&newcurrentrecord=1&newsortstring=' + para;
	  	break;
	case 'page' :
		document.frm.emu_action.value = 'newpage';
		document.frm.action += cS + 'newvalues=1&newpage=' + para;
		break;
	default :
	  	break
	}

  	document.frm.submit();
}

function submitcollection(colname,colid)
{
	clearNew();

	document.frm.emu_action.value = 'collection'
	document.frm.action = 'emuseum.asp?emu_action=collection&collection=' + colid + '&collectionname=' + encodeURIComponent(colname) + '&currentrecord=1';
  	document.frm.submit();
}

function openWindow(winURL,winName,winFlags)
{
    var myWindow=window.open(winURL,winName,winFlags);
    myWindow.focus();
}

function submitReport(reportname)
{
	document.report.action = 'eMuseum.asp?emu_action=report&report=' + reportname + '&sessionid=' + document.frm.sessionid.value;
	openWindow('','reportPopup','width=800,height=600,scrollbars=yes,resizable=yes');
	document.report.submit();
}

function changepage(page,profile)
{
	clearNew();
	document.frm.emu_action.value = 'newpage';

	if(document.frm.action.indexOf('?') > 0)
	{
		document.frm.action += '&';
	} else {
		document.frm.action += '?';
	}
	document.frm.action += 'newvalues=1&newpage=' + page + '&newprofile=' + profile;
	document.frm.submit();
}

function setMedia(filename,caption,title,mediatype) {
	//selects a particular media record for enlarging
	document.media.filename.value = filename;
	document.media.caption.value = caption;
	document.media.title.value = title;
	document.media.mediatype.value = mediatype;
	spawn('../html/media_enlarged.html','popup','440','500');
}

function spawn(url, nameW, w, h) {
  	if (navigator.appVersion.indexOf('4') != -1) {
		// Vars for centering the new window on Version 4 Browsers
		x4 = screen.width/2 - (w/2);
		y4 = screen.height/2 - (h/2);
		window.open(url, nameW, 'height='+h+',width='+w+',scrollbars=0,resizable=0,menubar=0,toolbar=0,status=0,location=0,directories=0,left=' + x4 + ',top=' + y4 + '');
  	} else {
    	window.open(url, nameW, 'height='+h+',width='+w+',scrollbars=0,resizable=0,menubar=0,toolbar=0,status=0,location=0,directories=0,left=150,top=200');
	}
}

function openImage(imgName,sTitle,sCaption){
	var sHTML = "<html><head><title>"+sTitle+"</title><link rel='stylesheet' href='../txtStyle.css' type='text/css'/></head><body><table cellpadding='0' cellspacing='0' border='0' width='100%'><tr valign='top'><td class='title'>"+sTitle+"</td><td align='right' class='txt'><a href='javascript:window.close();'>Close</a></td></tr><tr><td class='txt'>"+sCaption+"</td><td></td></tr></table><br><img src='getimage.asp?filename="+imgName+"&type=full' width='400' height='400' border='0' alt='"+sTitle+"'></body></html>";
	var theWindow = "";
	theWindow = window.open("","","height=540,width=540,resizable,scrollbars");
	if(theWindow){
    	theWindow.document.write(sHTML);
    	theWindow.document.close();
  	}
}
</script><script language="javascript">
			<!--
    function preloadArray(dir,arrayName) {
      if (document.images) {
        for (var i=0; i<eval(arrayName+'.length'); i++) {
          CURR_ARRAY_ITEM = eval(arrayName+'[i]');
          eval(CURR_ARRAY_ITEM+'_on = new Image()');
          eval(CURR_ARRAY_ITEM+'_on.src = dir+"'+CURR_ARRAY_ITEM+'_on.gif";');
          eval(CURR_ARRAY_ITEM+'_off = new Image()');
          eval(CURR_ARRAY_ITEM+'_off.src = dir+"'+CURR_ARRAY_ITEM+'_off.gif";');
        }
      }
    }

    var imageList = new Array('home','collections','bigsearch','help');
    preloadArray('../images/menu/','imageList');

    function rollIn(imgName) {
      if (document.images){
        document[imgName].src=eval(imgName + "_on.src");
      }
    }

    function rollOut(imgName) {
      if (document.images) {
        document[imgName].src=eval(imgName + "_off.src");
      }
    }

    function spawn(url, nameW, w, h) {
      if (navigator.appVersion.indexOf('4') != -1) {
        // Vars for centering the new window on Version 4 Browsers
        x4 = screen.width/2 - (w/2);
        y4 = screen.height/2 - (h/2);
        window.open(url, nameW, 'height='+h+',width='+w+',scrollbars=0,resizable=0,menubar=0,toolbar=0,status=0,location=0,directories=0,left=' + x4 + ',top=' + y4 + '');
      }
      else {
        window.open(url, nameW, 'height='+h+',width='+w+',scrollbars=0,resizable=0,menubar=0,toolbar=0,status=0,location=0,directories=0,left=150,top=200');
      }
    }
  //-->
		</script>
		<link rel="stylesheet" href="../txtStyle.css" type="text/css"/>
	</head>
	<body bgcolor="#FFFFFF" marginwidth="0" marginheight="0" leftmargin="0" topmargin="0" background="../images/bg.gif">
		<table width="100%" border="0" cellspacing="0" cellpadding="0">
			<tr><td width="1"><img src="../images/CDA.jpg" alt="Cloth Workers Digital Archive" width="800" height="200" border="0" usemap="#Map2"/></td>
				<td><img src="../images/spacerrightcda.jpg" alt="*" width="100%" height="200"/></td></tr></table>
		<map name="Map2"><area shape="rect" coords="20,103,302,123" href="http://www.clothworkers.co.uk"/>
			<area shape="rect" coords="617,104,719,121" href="http://www.leeds.ac.uk/ulita" alt="return to main"/>
		</map>
		<table border="0" cellspacing="0" cellpadding="0" height="100%"><tr><td background="../images/menuspacer.jpg" valign="top" width="155">
					<img src="../images/menutop.jpg" alt="*"/>
					<table border="0" cellspacing="0" cellpadding="5"><tr>
							<td colspan="2"><img src="../images/menu/quick_search.gif" width="66" height="7" border="0" alt="Quick Search"/></td></tr>
						<form name="frm" action="emuseum.asp?style=browse&currentrecord=1&profile=objects" method="post">
							<tr>
								<td><input type="text" name="quicksearch" size="7" style="background-color: FFFFFF; width: 80;" value=""/></td>
								<td><input type="image" name="quicksearch" src="../images/menu/go.gif" width="22" height="18" border="0" alt="Go" onClick="document.frm.submit();"/></td>
							</tr>
							<fields>

<!-- hidden state fields that do not need to be in URL -->

<input type="hidden" name="currentstateobjects" value=""/>
								<input type="hidden" name="currentstatepeople" value=""/>
								<input type="hidden" name="searchdescription"/>
								<input type="hidden" name="searchxml"/>
								<input type="hidden" name="term" value=""/>
								<input type="hidden" name="sessionid" value=""/>
								<input type="hidden" name="emu_action" value="quicksearch"/>
							</fields>
						</form>
						<tr>
							<td colspan="2"><img src="../images/px.gif" width="107" height="12" border="0" alt=""/><br><img src="../images/menu/home_on.gif" width="107" height="17" border="0" alt="Home" name="home"/><br><img src="../images/px.gif" width="107" height="3" border="0" alt=""/></td>
						</tr>
						<tr>
							<td colspan="2"><a href="javascript:submitpage('page','collections');" onmouseover="rollIn('collections');window.status='Collections'; return true;" onmouseout="rollOut('collections');window.status=''; return true;"><img src="../images/menu/collections_off.gif" width="107" height="17" border="0" alt="Collections" name="collections"/></a><br><img src="../images/px.gif" width="107" height="3" border="0" alt=""/></td>
						</tr>
						<tr>
							<td colspan="2">
								<a href="javascript:changepage('search_basic','objects');" onmouseover="rollIn('bigsearch');window.status='Search'; return true;" onmouseout="rollOut('bigsearch');window.status=''; return true;"><img src="../images/menu/bigsearch_off.gif" width="107" height="17" border="0" alt="Search" name="bigsearch"/></a><br><img src="../images/px.gif" width="107" height="3" border="0" alt=""/></td>
						</tr>
						<tr>
							<td colspan="2"><a href="javascript:submitpage('page','help');" onmouseover="rollIn('help');window.status='Help'; return true;" onmouseout="rollOut('help');window.status=''; return true;"><img src="../images/menu/help_off.gif" width="107" height="17" border="0" alt="Help" name="help"/></a><br><img src="../images/px.gif" width="107" height="3" border="0" alt=""/></td>
						</tr>
					</table>
				</td><td width="5"><img src="../images/px.gif" alt="*" width="10" height="1"/></td><td valign="top">
					<p><b>Welcome to the Clothworkers Digital Archive</b></p>
					<p>
			  This is an online catalogue of a selection of objects from the collection of The University of Leeds International Textiles Archive.  We are working towards making all our objects available in this format.
			  </p><p>
			  To search for an item, enter a keyword or any other search term in the box to the left.  Then click "go".  Alternatively click on the "Search" button to the left and follow the instructions.
				</p>
					<p>
						<b>The images and the metadata displayed in the Clothworker's Digital Archive ("the Works") are the Copyright of ULITA, the University of Leeds, unless otherwise stated. You may only use the Works for private research and study purposes only. Where used please acknowledge the ownership of ULITA, the University of Leeds, and the reference. If you are interested in reproducing any of ULITA's images please contact staff at ULITA.
 Although every effort will be made to locate copyright holders for permission, we would be grateful for any information which would help us complete or update our copyright records.  The permission to publish images does not extend to any material on this site identified as being the copyright of a third party. Authorisation to reproduce such material must be obtained from the copyright holders concerned.  

			</b>
					</p>
					<a href="http://emuseum.leeds.ac.uk/emuseum/code/emuseum.asp?newpage=collections">Direct to Collections</a>
				</td>
			</tr>
		</table>
	</body>
</html>

