var _condition = new Object();

	_condition.bukkenName = {
	                   "1":["","アパート","マンション","一戸建て","土地","店舗・事務所","倉庫・工場","その他","駐車場","収益物件","店舗","事務所","","住宅以外の建物全部","住宅以外の建物一部"],
	                   "3":["","アパート","マンション","一戸建て","土地","店舗・事務所","倉庫・工場","その他","駐車場","収益物件","店舗","事務所","","住宅以外の建物全部","住宅以外の建物一部"]
	                 };

	_condition.priceNumber = {
	                   "SALE1":[[500,1000,1500,2000,2500,3000,3500,4000,5000,6000,7000,8000,9000,10000,15000,20000],[500,1000,1500,2000,2500,3000,3500,4000,5000,6000,7000,8000,9000,10000,15000,20000]],
	                   "RENT1":[[3,3.5,4,4.5,5,5.5,6,6.5,7,7.5,8,8.5,9,9.5,10,11,12,13,14,15,16,17,18,19,20,30,50,100],[3,3.5,4,4.5,5,5.5,6,6.5,7,7.5,8,8.5,9,9.5,10,11,12,13,14,15,16,17,18,19,20,30,50,100]],
	                   "RENT2":[[10,15,20,25,30,35,40,50,100,200,300,500,800,1000],[10,15,20,25,30,35,40,50,100,200,300,500,800,1000]],
	                   "RENT3":[[0.3,0.5,0.8,1,1.5,2,2.5,3,4,5,6,7,8,9,10],[0.3,0.5,0.8,1,1.5,2,2.5,3,4,5,6,7,8,9,10]],
	                   "RENT4":[[3,3.5,4,4.5,5,5.5,6,6.5,7,7.5,8,8.5,9,9.5,10,11,12,13,14,15,16,17,18,19,20,30,50,100,200,300,500,800,1000],[3,3.5,4,4.5,5,5.5,6,6.5,7,7.5,8,8.5,9,9.5,10,11,12,13,14,15,16,17,18,19,20,30,50,100,200,300,500,800,1000]]
	               };

	_condition.areaNumber = {
	                   "AREA1":[[50,100,150,200,300,400,500,600,700,800,900,1000],[50,100,150,200,300,400,500,600,700,800,900,1000]],
	                   "AREA2":[[10,15,20,25,30,35,40,50,60,70,80,90,100,200,300,400,500,600,700,800,900,1000],[10,15,20,25,30,35,40,50,60,70,80,90,100,200,300,400,500,600,700,800,900,1000]]
	               };

	_condition.codawariName = {
	                   "A":"図面あり", "B":"画像あり", "C":"駐車場有",
	                   "110101":"楽器相談", "110201":"事務所可", "110301":"２人入居可", "110902":"ペット相談", "111002":"建築条件無",
	                   "210201":"都市ガス", "210301":"下水", "220301":"バス・トイレ別", "230101":"ガスコンロ", "230401":"システムキッチン", "220401":"追炊き", "240104":"エアコン", "250101":"トランクルーム", "250201":"床下収納", "250301":"W.INクローゼット", "290801":"ロフト付", "290901":"室内洗濯機置場", "260101":"CATV", "260201":"CSアンテナ", "260301":"BSアンテナ", "310101":"オートロック", "320101":"エレベータ", "290201":"専用庭", "290401":"バルコニー", "290101":"フローリング", "321001":"駐輪場有", "320901":"バイク置き場", "260503":"光ファイバー", "340401":"角部屋", "310501":"TVドアホン", "290501":"二世帯住宅", "290601":"バリアフリー", "330101":"デザイナーズ",
	                   "320801":"駐車場有", "340101":"1階限定", "340102":"2階以上", "340201":"最上階", "120101":"礼金無", "120201":"敷金無", "340301":"角地"
	               };

	_condition.codawariType = {
	                   "CF1":["A","B","340102","220301","*LINE*","290901","320801","240104","290101","310101","110902","230101","220401","120101","120201","340401","340201","310501","260101","260201","260301","290801","340101","110101","110201","330101","250301","260503","110301"],
	                   "CF2":["A","B","340102","320801","*LINE*","340401","310101","290401","320101","110902","321001","340201","210301","250101","230401","310501","320901","340101","290201","250301","250201"],
	                   "CF3":["A","B","320801","210301","*LINE*","310501","230401","250301","290601","250201","290501"],
	                   "CF4":["A","B","340301","210301","210301"],
	                   "CF5":["A","B","111002","210301","210301","340401"],
	                   "CF6":["A","B"]
	               };

	_condition.conditionpt = {
	                   "1_2"     : { "type":[4]          , "salerent":"SALE1", "kanri":false, "area":"AREA1", "madori":false, "kodawari":"CF5", "list":"LIST1-2" },
	                   "1_3"     : { "type":[5,6,7]      , "salerent":"SALE1", "kanri":false, "area":"AREA2", "madori":false, "kodawari":"CF6", "list":"LIST1-3" },
	                   "1_4"     : { "type":[2]          , "salerent":"SALE1", "kanri":false, "area":"AREA2", "madori":true , "kodawari":"CF2", "list":"LIST1-4" },
	                   "1_5"     : { "type":[3]          , "salerent":"SALE1", "kanri":false, "area":"AREA2", "madori":true , "kodawari":"CF3", "list":"LIST1-5" },
	                   "1_16"    : { "type":[10]         , "salerent":"SALE1", "kanri":false, "area":"AREA2", "madori":false, "kodawari":"CF6", "list":"LIST1-3" },
	                   "1_17"    : { "type":[11]         , "salerent":"SALE1", "kanri":false, "area":"AREA2", "madori":false, "kodawari":"CF6", "list":"LIST1-3" },
	                   "3_1"     : { "type":[1,2,3]      , "salerent":"RENT1", "kanri":true , "area":"AREA2", "madori":true , "kodawari":"CF1", "list":"LIST3-1" },
	                   "3_2"     : { "type":[4]          , "salerent":"RENT2", "kanri":true , "area":"AREA1", "madori":false, "kodawari":"CF4", "list":"LIST3-2" },
	                   "3_3"     : { "type":[5,6,7]      , "salerent":"RENT2", "kanri":true , "area":"AREA2", "madori":false, "kodawari":"CF6", "list":"LIST3-3" },
	                   "3_8"     : { "type":[8]          , "salerent":"RENT3", "kanri":false, "area":""     , "madori":false, "kodawari":"CF6", "list":"LIST3-4" },
	                   "3_16"    : { "type":[10]         , "salerent":"RENT2", "kanri":true , "area":"AREA2", "madori":false, "kodawari":"CF6", "list":"LIST3-3" },
	                   "3_17"    : { "type":[11]         , "salerent":"RENT2", "kanri":true , "area":"AREA2", "madori":false, "kodawari":"CF6", "list":"LIST3-3" },
	                   "oem1_1"  : { "type":[2,3]        , "salerent":"SALE1", "kanri":false, "area":"AREA2", "madori":true , "kodawari":"CF6", "list":"LIST1-1" },
	                   "oem1_2"  : { "type":[4]          , "salerent":"SALE1", "kanri":false, "area":"AREA1", "madori":false, "kodawari":"CF6", "list":"LIST1-2" },
	                   "oem1_3"  : { "type":[5,6,7]      , "salerent":"SALE1", "kanri":false, "area":"AREA2", "madori":false, "kodawari":"CF6", "list":"LIST1-3" },
	                   "oem1_4"  : { "type":[2]          , "salerent":"SALE1", "kanri":false, "area":"AREA2", "madori":true , "kodawari":"CF6", "list":"LIST1-4" },
	                   "oem1_5"  : { "type":[3]          , "salerent":"SALE1", "kanri":false, "area":"AREA2", "madori":true , "kodawari":"CF6", "list":"LIST1-5" },
	                   "oem1_9"  : { "type":[9]          , "salerent":"SALE1", "kanri":false, "area":"AREA2", "madori":true , "kodawari":"CF6", "list":"LIST1-6" },
	                   "oem1_10" : { "type":[5]          , "salerent":"SALE1", "kanri":false, "area":"AREA2", "madori":false, "kodawari":"CF6", "list":"LIST1-3" },
	                   "oem1_11" : { "type":[6]          , "salerent":"SALE1", "kanri":false, "area":"AREA2", "madori":false, "kodawari":"CF6", "list":"LIST1-3" },
	                   "oem1_12" : { "type":[7]          , "salerent":"SALE1", "kanri":false, "area":"AREA2", "madori":false, "kodawari":"CF6", "list":"LIST1-3" },
	                   "oem1_13" : { "type":[13]         , "salerent":"SALE1", "kanri":false, "area":"AREA2", "madori":false, "kodawari":"CF6", "list":"LIST1-7" },
	                   "oem1_14" : { "type":[14]         , "salerent":"SALE1", "kanri":false, "area":"AREA2", "madori":false, "kodawari":"CF6", "list":"LIST1-7" },
	                   "oem1_16" : { "type":[10]         , "salerent":"SALE1", "kanri":false, "area":"AREA2", "madori":false, "kodawari":"CF6", "list":"LIST1-3" },
	                   "oem1_17" : { "type":[11]         , "salerent":"SALE1", "kanri":false, "area":"AREA2", "madori":false, "kodawari":"CF6", "list":"LIST1-3" },
	                   "oem3_1"  : { "type":[1,2,3]      , "salerent":"RENT1", "kanri":true , "area":"AREA2", "madori":true , "kodawari":"CF6", "list":"LIST3-1" },
	                   "oem3_2"  : { "type":[4]          , "salerent":"RENT2", "kanri":true , "area":"AREA1", "madori":false, "kodawari":"CF6", "list":"LIST3-2" },
	                   "oem3_3"  : { "type":[5,6,7]      , "salerent":"RENT2", "kanri":true , "area":"AREA2", "madori":false, "kodawari":"CF6", "list":"LIST3-3" },
	                   "oem3_4"  : { "type":[1,2]        , "salerent":"RENT1", "kanri":true , "area":"AREA2", "madori":true , "kodawari":"CF6", "list":"LIST3-1" },
	                   "oem3_5"  : { "type":[3]          , "salerent":"RENT1", "kanri":true , "area":"AREA2", "madori":true , "kodawari":"CF6", "list":"LIST3-1" },
	                   "oem3_6"  : { "type":[2,3]        , "salerent":"RENT1", "kanri":true , "area":"AREA2", "madori":true , "kodawari":"CF6", "list":"LIST3-1" },
	                   "oem3_8"  : { "type":[8]          , "salerent":"RENT3", "kanri":false, "area":""     , "madori":false, "kodawari":"CF6", "list":"LIST3-4" },
	                   "oem3_10" : { "type":[5]          , "salerent":"RENT2", "kanri":true , "area":"AREA2", "madori":false, "kodawari":"CF6", "list":"LIST3-3" },
	                   "oem3_11" : { "type":[6]          , "salerent":"RENT2", "kanri":true , "area":"AREA2", "madori":false, "kodawari":"CF6", "list":"LIST3-3" },
	                   "oem3_12" : { "type":[7]          , "salerent":"RENT2", "kanri":true , "area":"AREA2", "madori":false, "kodawari":"CF6", "list":"LIST3-3" },
	                   "oem3_15" : { "type":[1,2,3,5,6,7], "salerent":"RENT4", "kanri":true , "area":"AREA2", "madori":true , "kodawari":"CF6", "list":"LIST3-1" },
	                   "oem3_16" : { "type":[10]         , "salerent":"RENT2", "kanri":true , "area":"AREA2", "madori":false, "kodawari":"CF6", "list":"LIST3-3" },
	                   "oem3_17" : { "type":[11]         , "salerent":"RENT2", "kanri":true , "area":"AREA2", "madori":false, "kodawari":"CF6", "list":"LIST3-3" }
	               };

function getConditionHTML(data) {

	_condition.ptname = data.oem + data.tk + "_" + data.bsg;
	if(typeof(_condition.conditionpt[_condition.ptname]) == "undefined") return;

	var conditionhtml = '<form id="conditionForm">';

	conditionhtml += '<dl id="condition_bukken">';
	conditionhtml += '<dt><img src="/homes/images/label/bukken_' + homesGlobal.color + '.gif" alt="物件種別" width="53" height="17" title="" /></dt>';
	conditionhtml += '<dd><ul>';
	for (var i = 0; i < _condition.conditionpt[_condition.ptname].type.length; i++) {
		var _item = _condition.bukkenName[data.tk][_condition.conditionpt[_condition.ptname].type[i]];
		var _value = _condition.conditionpt[_condition.ptname].type[i];
		if (_condition.conditionpt[_condition.ptname].type.length == 1) {
			conditionhtml += '<li>' + _item + '</li>';
			conditionhtml += '<li><input type="hidden" name="bs" value="' + _value + '" /></li>';
		} else {
			conditionhtml += '<li><input type="checkbox" name="bs" id="bs' + i + '" value="' + _value + '" checked onclick="ConditionSearch();" /><label for="" onclick="CheckClick(\'bs' + i + '\');ConditionSearch();">' + _item + '</label></li>';
		}
	}

	conditionhtml += '</ul></dd>';

	conditionhtml += '</dl>';
	conditionhtml += '<dl id="condition_chinryou">';
	if (data.tk == "1") {
		conditionhtml += '<dt><img src="/homes/images/label/kakaku_' + homesGlobal.color + '.gif" alt="価格" width="53" height="17" title="" /></dt>';
	} else if (data.tk == "3") {
		conditionhtml += '<dt><img src="/homes/images/label/cnintai_' + homesGlobal.color + '.gif" alt="賃料" width="53" height="17" title="" /></dt>';
	}
	conditionhtml += '<dd id="SALE1">';
	conditionhtml += '<select name="sale1" onchange="ConditionSearch();">';

	conditionhtml += '<option value="" selected="selected">下限無し</option>';
	for (var i = 0; i < _condition.priceNumber[_condition.conditionpt[_condition.ptname].salerent][0].length; i++) {
		var _item = _condition.priceNumber[_condition.conditionpt[_condition.ptname].salerent][0][i] + "万円";
		var _value = _condition.priceNumber[_condition.conditionpt[_condition.ptname].salerent][0][i];
		conditionhtml += '<option value="' + _value + '">' + _item + '</option>';
	}

	conditionhtml += '</select>';
	conditionhtml += '<span>～</span>';
	conditionhtml += '<select name="sale2" onchange="ConditionSearch();">';
	for (var i = 0; i < _condition.priceNumber[_condition.conditionpt[_condition.ptname].salerent][1].length; i++) {
		var _item = _condition.priceNumber[_condition.conditionpt[_condition.ptname].salerent][1][i] + "万円";
		var _value = _condition.priceNumber[_condition.conditionpt[_condition.ptname].salerent][1][i];
		conditionhtml += '<option value="' + _value + '">' + _item + '</option>';
	}
	conditionhtml += '<option value="" selected="selected">上限無し</option>';
	conditionhtml += '</select>';

	if (_condition.conditionpt[_condition.ptname].kanri) {
	conditionhtml += '<input type="checkbox" name="kanri" id="kanri" value="" onclick="ConditionSearch();" /><label for="" onclick="CheckClick(\'kanri\');ConditionSearch();">共益費／管理費を含む</label>';
	}

	conditionhtml += '</dd>';
	conditionhtml += '</dl>';

	if (_condition.conditionpt[_condition.ptname].area != "") {
		conditionhtml += '<dl id="condition_menseki">';
		conditionhtml += '<dt><img src="/homes/images/label/menseki_' + homesGlobal.color + '.gif" alt="面積" width="53" height="17" title="" /></dt>';
		conditionhtml += '<dd id="AREA1">';
		conditionhtml += '<select name="area1" onchange="ConditionSearch();">';

		conditionhtml += '<option value="" selected="selected">下限無し</option>';
		for (var i = 0; i < _condition.areaNumber[_condition.conditionpt[_condition.ptname].area][0].length; i++) {
			var _item = _condition.areaNumber[_condition.conditionpt[_condition.ptname].area][0][i];
			var _value = _condition.areaNumber[_condition.conditionpt[_condition.ptname].area][0][i];
			conditionhtml += '<option value="' + _value + '">' + _item + 'm2' + '</option>';
		}

		conditionhtml += '</select>';
		conditionhtml += '<span>～</span>';
		conditionhtml += '<select name="area2" onchange="ConditionSearch();">';
		for (var i = 0; i < _condition.areaNumber[_condition.conditionpt[_condition.ptname].area][1].length; i++) {
			var _item = _condition.areaNumber[_condition.conditionpt[_condition.ptname].area][1][i];
			var _value = _condition.areaNumber[_condition.conditionpt[_condition.ptname].area][1][i];
			conditionhtml += '<option value="' + _value + '">' + _item + 'm2' + '</option>';
		}
		conditionhtml += '<option value="" selected="selected">上限無し</option>';
		conditionhtml += '</select>';
		conditionhtml += '</dd>';
		conditionhtml += '</dl>';
	}

	if (_condition.conditionpt[_condition.ptname].madori) {
		conditionhtml += '<dl id="condition_madori">';
		conditionhtml += '<dt><img src="/homes/images/label/madori_' + homesGlobal.color + '.gif" alt="間取り" width="40" height="17" title="" /></dt>';
		conditionhtml += '<dd><ul>';
		conditionhtml += '<li><input type="checkbox" name="madori" id="madori11" value="11" onclick="ConditionSearch();" /><label for="" onclick="CheckClick(\'madori11\');ConditionSearch();">1R</label></li>';
		conditionhtml += '<li><input type="checkbox" name="madori" id="madori12" value="12" onclick="ConditionSearch();" /><label for="" onclick="CheckClick(\'madori12\');ConditionSearch();">1K</label></li>';
		conditionhtml += '<li><input type="checkbox" name="madori" id="madori13" value="13" onclick="ConditionSearch();" /><label for="" onclick="CheckClick(\'madori13\');ConditionSearch();">1DK</label></li>';
		conditionhtml += '<li><input type="checkbox" name="madori" id="madori15" value="15" onclick="ConditionSearch();" /><label for="" onclick="CheckClick(\'madori15\');ConditionSearch();">1LDK</label></li>';
		conditionhtml += '<li><input type="checkbox" name="madori" id="madori22" value="22" onclick="ConditionSearch();" /><label for="" onclick="CheckClick(\'madori22\');ConditionSearch();">2K</label></li>';
		conditionhtml += '<li><input type="checkbox" name="madori" id="madori23" value="23" onclick="ConditionSearch();" /><label for="" onclick="CheckClick(\'madori23\');ConditionSearch();">2DK</label></li>';
		conditionhtml += '<li><input type="checkbox" name="madori" id="madori25" value="25" onclick="ConditionSearch();" /><label for="" onclick="CheckClick(\'madori25\');ConditionSearch();">2LDK</label></li>';
		conditionhtml += '<li><input type="checkbox" name="madori" id="madori32" value="32" onclick="ConditionSearch();" /><label for="" onclick="CheckClick(\'madori32\');ConditionSearch();">3K</label></li>';
		conditionhtml += '<li><input type="checkbox" name="madori" id="madori33" value="33" onclick="ConditionSearch();" /><label for="" onclick="CheckClick(\'madori33\');ConditionSearch();">3DK</label></li>';
		conditionhtml += '<li><input type="checkbox" name="madori" id="madori35" value="35" onclick="ConditionSearch();" /><label for="" onclick="CheckClick(\'madori35\');ConditionSearch();">3LDK</label></li>';
		conditionhtml += '<li><input type="checkbox" name="madori" id="madori42" value="42" onclick="ConditionSearch();" /><label for="" onclick="CheckClick(\'madori42\');ConditionSearch();">4K</label></li>';
		conditionhtml += '<li><input type="checkbox" name="madori" id="madori43" value="43" onclick="ConditionSearch();" /><label for="" onclick="CheckClick(\'madori43\');ConditionSearch();">4DK</label></li>';
		conditionhtml += '<li><input type="checkbox" name="madori" id="madori45" value="45-" onclick="ConditionSearch();" /><label for="" onclick="CheckClick(\'madori45\');ConditionSearch();">4LDK以上</label></li>';
		conditionhtml += '</ul></dd>';
	}

	conditionhtml += '</dl>';
	conditionhtml += '<dl id="condition_kodawari">';
	conditionhtml += '<dt><img src="/homes/images/label/kodawari_' + homesGlobal.color + '.gif" alt="こだわり条件" width="76" height="17" title="" /></dt>';
	conditionhtml += '<dd>';
	conditionhtml += '<ul id="CF">';
	var _kodawariflag = true;
	var _itemnoarray = _condition.codawariType[_condition.conditionpt[_condition.ptname].kodawari];
	for (var i = 0; i < _itemnoarray.length; i++) {
		var _value = _itemnoarray[i];
		var _item = _condition.codawariName[_value];
		if (_value == "*LINE*") {
			_kodawariflag = false;
		} else {
			if (_kodawariflag) {
				conditionhtml += '<li class="default">';
			} else {
				conditionhtml += '<li>';
			}
			conditionhtml += '<input type="checkbox" name="ccf" id="ccf' + i + '" value="' + _value + '" onclick="ConditionSearch();" /><label for="" onclick="CheckClick(\'ccf' + i + '\');ConditionSearch();">' + _item + '</label></li>';
		}
	}

	conditionhtml += '</ul>';
	conditionhtml += '</dd>';
	conditionhtml += '</dl>';
	if (!_kodawariflag) {
		conditionhtml += '<div class="posR"><a href="javascript:void(0);" onclick="kodawari(this);return false;">&gt;&gt;&nbsp;もっと細かい条件を指定する</a></div>';
	}
	conditionhtml += '</form>';

	return conditionhtml;
}

function getListType(data) {
	_condition.ptname = data.oem + data.tk + "_" + data.bsg;

	if(typeof(_condition.conditionpt[_condition.ptname]) == "undefined") return;

	return _condition.conditionpt[_condition.ptname].list;

}

function getListHeadHTML(listtype) {
	var headhtml = "";
	if (listtype=="LIST1-1") {
		headhtml += "<th>間取り</th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('area');return false;\">面積</a></th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('period');return false;\">築年数</a><br />方位</th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('fee');return false;\">価格</a></th>";
	}

	if (listtype=="LIST1-2") {
		headhtml += "<th>建ぺい率<br />容積率</th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('area_land');return false;\">土地面積</a></th>";
		headhtml += "<th>土地権利</th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('fee');return false;\">価格</a><br />坪単価</th>";
	}

	if (listtype=="LIST1-3") {
		headhtml += "<th>所在地</th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('period');return false;\">築年数</a></th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('area');return false;\">面積</a><br />所在階</th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('fee');return false;\">価格</a><br />管理費等</th>";
	}

	if (listtype=="LIST1-4") {
		headhtml += "<th>間取り<br />総戸数</th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('area');return false;\">専有面積</a><br />バルコニー面積</th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('period');return false;\">築年数</a><br />方位</th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('fee');return false;\">価格</a></th>";
	}

	if (listtype=="LIST1-5") {
		headhtml += "<th>間取り<br />階数</th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('area');return false;\">建物面積</a><br /><a href=\"javascript:void(0)\" onclick=\"searchSortChange('area_land');return false;\">土地面積</a></th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('period');return false;\">築年数</a><br />方位</th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('fee');return false;\">価格</a></th>";
	}

	if (listtype=="LIST1-6") {
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('area');return false;\">建物（専有）面積</a><br /><a href=\"javascript:void(0)\" onclick=\"searchSortChange('area_land');return false;\">土地面積</a></th>";
		headhtml += "<th>想定利回り（％）</th>";
		headhtml += "<th>所在階</th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('fee');return false;\">価格</a></th>";
	}

	if (listtype=="LIST1-7") {
		headhtml += "<th>所在地</th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('period');return false;\">築年数</a></th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('area');return false;\")>面積</a></th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('fee');return false;\">価格</a><br />管理費等</th>";
	}

	if (listtype=="LIST3-1") {
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('area');return false;\">面積</a><br />間取り</th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('period');return false;\">築年数</a><br />方位</th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('fee');return false;\">賃料</a><br />管理費等</th>";
		headhtml += "<th>敷金（保証金）<br />礼金（敷引金）</th>";
	}

	if (listtype=="LIST3-2") {
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('area_land');return false;\">土地面積</a></th>";
		headhtml += "<th>建ぺい率<br />容積率</th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('fee');return false;\">賃料</a><br />坪単価</th>";
		headhtml += "<th>敷金（保証金）<br />礼金（敷引金）</th>";
	}

	if (listtype=="LIST3-3") {
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('area');return false;\">面積</a></th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('period');return false;\">築年数</a><br />駐車場</th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('fee');return false;\">賃料</a><br />坪単価</th>";
		headhtml += "<th>管理費等<br />敷金（保証金）<br />礼金（敷引金）</th>";
	}

	if (listtype=="LIST3-4") {
		headhtml += "<th>所在地</th>";
		headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('fee');return false;\">賃料</a><br />管理費等</th>";
		headhtml += "<th>敷金（保証金）<br />礼金（敷引金）</th>";
	}

	headhtml += "<th><a href=\"javascript:void(0)\" onclick=\"searchSortChange('pict');return false;\">画像の有無</a></th>";
	headhtml += "<th style=\"width:24px;\">一括詳細</th>";

	return headhtml;
}

function getListHtml(data, listtype) {
	var listhtml = '';
	if(data.length == 0) {
		listhtml += '<br><br><center>検索結果は、0件です。</center>';
	} else {
		listhtml += '<table summary="検索結果リスト">';
		listhtml += '<thead class="typeA">';
		listhtml += '<tr>' + getListHeadHTML(listtype) + '</tr>';
		listhtml += '</thead>';
		listhtml += '<tbody>';
		var htmlarray = new Array();
		for(var i=0;i<data.length;i++){
			htmlarray[i] = '';
			if(i % 2 == 0){
				htmlarray[i] += '<tr class="zebra" onmouseover="setMarker('+data[i].ID+');return false;">';
			} else {
				htmlarray[i] += '<tr>';
			}
			htmlarray[i] += '<td class="col1" onmouseover="setMarker('+data[i].ID+');return false;"><span>' + data[i].col1_1;
			if(data[i].col1_1m2){
				htmlarray[i] += '<img src="/homes/images/icon_m2.gif" alt="平方メートル" width="12" height="10" />';
			}
			htmlarray[i] += '</span><span>' + data[i].col1_2;
			if(data[i].col1_2m2){
				htmlarray[i] += '<img src="/homes/images/icon_m2.gif" alt="平方メートル" width="12" height="10" />';
			}
			htmlarray[i] += '</span></td><td class="col2"><span>' + data[i].col2_1;
			if(data[i].col2_1m2){
				htmlarray[i] += '<img src="/homes/images/icon_m2.gif" alt="平方メートル" width="12" height="10" />';
			}
			htmlarray[i] += '</span><span>' + data[i].col2_2;
			if(data[i].col2_2m2){
				htmlarray[i] += '<img src="/homes/images/icon_m2.gif" alt="平方メートル" width="12" height="10" />';
			}
			htmlarray[i] += '</span></td>';
			if (data[i].col4_1 != "") {
				htmlarray[i] += '<td class="col3">';
			} else {
				htmlarray[i] += '<td class="col4">';
			}
			htmlarray[i] += '<span>' + data[i].col3_1;
			if(data[i].col3_1m2){
				htmlarray[i] += '<img src="/homes/images/icon_m2.gif" alt="平方メートル" width="12" height="10" />';
			}
			htmlarray[i] += '</span><span>' + data[i].col3_2;
			if(data[i].col3_2m2){
				htmlarray[i] += '<img src="/homes/images/icon_m2.gif" alt="平方メートル" width="12" height="10" />';
			}
			htmlarray[i] += '</span></td>';
			if (data[i].col4_1 != "") {
				htmlarray[i] += '<td class="col4"><span>' + data[i].col4_1;
				if(data[i].col4_1m2){
					htmlarray[i] += '<img src="/homes/images/icon_m2.gif" alt="平方メートル" width="12" height="10" />';
				}
				htmlarray[i] += '</span><span>' + data[i].col4_2;
				if(data[i].col4_2m2){
					htmlarray[i] += '<img src="/homes/images/icon_m2.gif" alt="平方メートル" width="12" height="10" />';
				}
				htmlarray[i] += '</span><span>' + data[i].col4_3;
				if(data[i].col4_3m2){
					htmlarray[i] += '<img src="/homes/images/icon_m2.gif" alt="平方メートル" width="12" height="10" />';
				}
				htmlarray[i] += '</span>';
				htmlarray[i] += '</td>';
			}
			htmlarray[i] += '<td class="col5">';
			if (data[i].DETAILURL != null) {
				var url = homesGlobal.list.detailurl2;
				url += "b[]=" + data[i].ID;
				url += "/tk=" + homesGlobal.tk + "/";
				if (homesGlobal.gyo != "" && homesGlobal.gyo != null) {
					url += "o=" + homesGlobal.gyo;
					if (homesGlobal.route != "" && homesGlobal.route != null) {
						url += "/route=" + homesGlobal.route;
					}
				}
				htmlarray[i] += '<a href="'  + url + '" target="_blank">';
				if (data[i].PHOTOASPECT != null) {
					htmlarray[i] += '<img src="' + data[i].PHOTOASPECT + '" alt="" width="52" />';
				}
				htmlarray[i] += '<span>詳細表示</span></a>';
			}
			htmlarray[i] += '</td>';
			htmlarray[i] += '<td class="col6"><input type="checkbox" name="b[]" value="' + data[i].ID + '" /></td>';
			htmlarray[i] += '</tr>';
		}
		listhtml += htmlarray.join('');
		listhtml += '</tbody>';
		listhtml += '</table>';
	}
	return listhtml;
}