<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
		<link rel='stylesheet' type='text/css' href='admin/style/style.css' />
		<title>圈子聚合首页后台管理</title>
	</head>
	<body>
		<!--{if("links_2" == action)}-->
		<script language="javascript">
function setini( isnext ){
	var obj = document.all('topicid');
	var links = opener.document.getElementById('autopage').value;
	var tep = 0;
	for(var i=0; i<obj.length; i++){
		if(obj[i].checked != true){
			continue;
		}
		
		var ar = obj[i].value.split(';');
		var temstr = '';
		
		temstr +=  ' <table width="98%" border="0" align="center" cellpadding="0" cellspacing="0"><tr>';
		temstr +=  '<td width="137" height="20" align="left" class="shadowt2" style="white-space:nowrap" style="white-space:nowrap">·<a target="_blank" href="my_group_topic.aspx?TopicID=' + ar[0] + '" class="LinkRed8" >' + ar[1] + '</a> </td>';		
		while(true){
			i++;

			if(i<obj.length){
				if(obj[i].checked != true){
					continue;
				}else{
				ar = obj[i].value.split(';');
					temstr +=  '<td align="left" class="shadowt2" style="white-space:nowrap" style="white-space:nowrap">·<a target="_blank" href="my_group_topic.aspx?TopicID=' + ar[0] + '" class="LinkRed8" >' + ar[1] + '</a></td></tr></table>';
					break;
				}
			}else{
					temstr +=  '<td align="left" class="shadowt2"> </td></tr></table>';
				break;
			}
		}
		
		if(links.indexOf(temstr) == -1){
			links += temstr;
		}else continue;
	}
	
	if( 1 == isnext){
		opener.document.getElementById('autopage').value = links;
		document.getElementById('msg').innerHTML = '暂存完成，继续选择...';
	}else 
	{
		opener.document.getElementById('links_2').value = links;
		opener.document.getElementById('autopage').value = '';	
		window.close();
	}
}
		</script>
		<form id="form1" name="form1" method="post" action="">
			<table align="center" cellpadding="4" cellspacing="1" border="1" class="maintable">
				<tr>
					<th colspan="3">
						圈子聚合</th>
				</tr>
				<tr>
					<td width="10">&nbsp;</td>
					<td width="20">ID</td>
					<td>标题&nbsp;</td>
				</tr>
				<!--{foreach (System.Data.DataRow dr in activedata.Rows)} -->
				<tr>
					<td><input type="checkbox" id="topicid" name="topicid" value="<%=dr["topicid"]%>;<%=Text.Left(dr["title"].ToString(), 18, true)%>;<%=dr["GroupName"]%>" class="checkbox"/></td>
					<td><%=dr["topicid"]%></td>
					<td><a href="topic.aspx?topicid=<%=dr["topicid"]%>" target="_blank"><%=dr["title"]%>&nbsp;</a></td>
				</tr>
				<!--{endforeach}-->
				<tr>
					<td class="title" colspan="3"><!--#include file="_temppager.htm"--></td>
				</tr>
			</table>
			<br />
			<input type="button" class="button_off" onmouseover="this.className='button_on'" onmouseout="this.className='button_off'"
				name="Submit" onclick="setini(1)" value="暂存选项，继续选择下一页数据" /> <input type="button" class="button_off" onmouseover="this.className='button_on'" onmouseout="this.className='button_off'"
				name="Submit" onclick="setini(0)" value="选择完成，确认提交" />
		</form>
		<div style="flaot:left" id="msg" name="msg">&nbsp;</div>
		<!--{else}-->
		<script language="javascript">
function setini( isnext ){
	var obj = document.all('topicid');
	var links = opener.document.getElementById('autopage').value;
	var tep = 0;
	for(var i=0; i<obj.length; i++){
		if(obj[i].checked != true){
			continue;
		}
		
		var ar = obj[i].value.split(';');
		var temstr = '';
                    
		temstr +=  '<table width="98%" height="23" border="0" align="center" cellpadding="0" cellspacing="0"><tr>';
		temstr +=  '<td  height="20" align="left" width="300" class="shadowt2" style="white-space:nowrap">';
		
		temstr +=  '&nbsp;<img src="hdimage/images/quan_r1_1.jpg" width="4" height="7" /><a target="_blank" href="my_group_topic.aspx?TopicID='+ ar[0] +'" class="LinkRed2" > [ '+ ar[2]  +']  '+ ar[1] +'</a> </td>';
		temstr +=  '<td width="64" align="left" class="shadowt2" style="white-space:nowrap" style="white-space:nowrap"><a href="user_info.aspx?name='+ ar[3]  +'" target="_blank"  class="LinkRed2">'+ ar[3]  +'</a></td>';
		
		while(true){
			i++;
			if(i<obj.length){
				if(obj[i].checked != true){
					continue;
				}else{
					ar = obj[i].value.split(';');
					temstr +=  '<td align="left" class="shadowt2" style="white-space:nowrap">&nbsp;<img src="hdimage/images/quan_r1_1.jpg" width="4" height="7" /><a target="_blank"  href="my_group_topic.aspx?TopicID='+ ar[0] +'" class="LinkRed2" > [ '+ ar[2]  +']  '+ ar[1] +'</a> </td>';
					temstr +=  '<td width="64" align="left" class="shadowt2" style="white-space:nowrap"><a href="user_info.aspx?name='+ ar[3]  +'" target="_blank"  class="LinkRed2">'+ ar[3]  +'</a></td>';
					temstr +=  '</tr></table>';
					break;
				}
			}else{
					temstr +=  '<td align="left" class="shadowt2">&nbsp;</td><td width="64" align="left" class="shadowt2">&nbsp;</td></tr></table>';
				break;
			}
		}
		
		if(links.indexOf(temstr) == -1){
			links += temstr;
		}else continue;
	}
	
	if( 1 == isnext){
		opener.document.getElementById('autopage').value = links;
		document.getElementById('msg').innerHTML = '暂存完成，继续选择...';
	}else 
	{
		opener.document.getElementById('links_3').value = links;
		opener.document.getElementById('autopage').value = '';	
		window.close();
	}
}
		</script>
		<form id="form1" name="form1" method="post" action="">
			<table align="center" cellpadding="4" cellspacing="1" border="1" class="maintable">
				<tr>
					<th colspan="3">
						圈子聚合</th>
				</tr>
				<tr>
					<td width="10">&nbsp;</td>
					<td width="20">ID</td>
					<td>标题&nbsp;</td>
				</tr>
				<!--{foreach (System.Data.DataRow dr in activedata.Rows)} -->
				<tr>
					<td><input type="checkbox" id="topicid" name="topicid" class="checkbox" value="<%=dr["topicid"]%>;<%=Text.Left(dr["title"].ToString(), 16, true)%>;<%=dr["GroupName"]%>;<%=dr["PostUserName"]%>" /></td>
					<td><%=dr["topicid"]%></td>
					<td><a href="topic.aspx?topicid=<%=dr["topicid"]%>" target="_blank"><%=dr["title"]%>&nbsp;</a></td>
				</tr>
				<!--{endforeach}-->
				<tr>
					<td colspan="3" class="title"><!--#include file="_temppager.htm"--></td>
				</tr>
			</table>
			<br />
			<input type="button" class="button_off" onmouseover="this.className='button_on'" onmouseout="this.className='button_off'"
				name="Submit" onclick="setini(1)" value="暂存选项，继续选择下一页数据" /> <input type="button" class="button_off" onmouseover="this.className='button_on'" onmouseout="this.className='button_off'"
				name="Submit" onclick="setini(0)" value="选择完成，确认提交" />
		</form>
		<div style="flaot:left" id="msg" name="msg">&nbsp;</div>
		<!--{endif}-->
	</body>
</html>
