function view_more_msg(eid)
{
	var vtitle = '查看更多留言';
	var vwidth = 600;
	var vheight =500;
	var vurl = 'dv_event_msg_more.php';
	var pid = '<?php echo $se_pid;?>';
	
	var win = new Window({className:"alphacube", title: vtitle, width: vwidth, height: vheight, url: vurl + "?evid=" + eid + "&pid=" + pid});
	win.showCenter(true);
	win.setDestroyOnClose();
};

function view_more_matchs(eid)
{
	var vtitle = '查看更多相關小人物';
	var vwidth = 600;
	var vheight =500;
	var vurl = 'dv_match_more.php';
	
	var win = new Window({className:"alphacube", title: vtitle, width: vwidth, height: vheight, url: vurl + "?evid=" + eid});
	win.showCenter(true);
	win.setDestroyOnClose();
};

function view_tag_matchs(typ,tag)
{
	var vtitle = '查看更多相關小人物';
	var vwidth = 600;
	var vheight =500;
	var vurl = 'view_match_spc.php';
	
	var win = new Window({className:"alphacube", title: vtitle, width: vwidth, height: vheight, url: vurl + "?typ=" + typ + "&key="+ encodeURI(tag)});
	win.showCenter(true);
	win.setDestroyOnClose();
};

function dv_add_newpage(def_name)
{
	var vtitle = '新增小人物';
	var vwidth = 470;
	var vheight =310;
	var vurl = 'dv_newpage.php';
	
	var win = new Window({className:"alphacube", title: vtitle, width: vwidth, height: vheight, url: vurl + "?dfname="+ encodeURI(def_name)});
	win.showCenter(true);
	win.setDestroyOnClose();
};

function dv_chg_nickname(pid)
{
	var vtitle = '變更暱稱';
	var vwidth = 370;
	var vheight =160;
	var vurl = 'dve_chg_nick.php';
	
	var win = new Window({className:"alphacube", title: vtitle, width: vwidth, height: vheight, url: vurl + "?pid="+ pid});
	win.showCenter(true);
	win.setDestroyOnClose();
};

function event_expand(tyd,eid,pid)
{
	var vtitle = '';
	var vwidth = 0;
	var vheight =0;
	var vurl = '';
	
	switch(tyd)
	{
		case 1:  //留言
			vtitle = '我要留言';
			vwidth = 513;
			vheight = 244;
			vurl = 'dv_event_msg.php';
			break    
		case 2:  //照片
			vtitle = '我要上傳照片';
			vwidth = 513;
			vheight = 244;
			vurl = 'dv_event_photo.php';
			break
		case 3:  //補充
			vtitle = '我要補充內容';
			vwidth = 513;
			vheight = 244;
			vurl = 'dv_event_text.php';
			break
	}
	var win = new Window({className:"alphacube", title: vtitle, width: vwidth, height: vheight, url: vurl + "?evid=" + eid + "&pid=" + pid});
	win.showCenter(true);
	win.setDestroyOnClose();
};

function cty_expand(tyd,pid)
{
	var vtitle = '';
	var vwidth = 0;
	var vheight =0;
	var vurl = '';
	
	switch(tyd)
	{
		case 1:
			vtitle = '編輯學歷 - 小學，中學';
			vwidth = 513;
			vheight = 238;
			vurl = 'dv_edu.php';
			break    
		case 2:
			vtitle = '編輯學歷 - 高中以上';
			vwidth = 513;
			vheight = 294;
			vurl = 'dv_edu2.php';
			break
		case 3:
			vtitle = '編輯 - 曾經是老師';
			vwidth = 513;
			vheight = 304;
			vurl = 'dv_exp1.php';
			break
		case 4:
			vtitle = '編輯 - 其他經歷身分';
			vwidth = 513;
			vheight = 290;
			vurl = 'dv_exp2.php';
			break
		case 5:
			vtitle = '編輯 - 上傳照片';
			vwidth = 483;
			vheight = 173;
			vurl = 'dv_event_pic.php';
			break
		case 6:
			vtitle = '編輯 - 大事件';
			vwidth = 483;
			vheight = 188;
			vurl = 'dv_event.php';
			break
		case 7:
			vtitle = '編輯 - 隨便寫寫';
			vwidth = 483;
			vheight = 188;
			vurl = 'dv_notes.php';
			break
		case 8:
			vtitle = '編輯 - 出生資料';
			vwidth = 513;
			vheight = 133;
			vurl = 'dv_birth.php';
			break
		case 9:
			vtitle = '編輯 - 聯絡資料';
			vwidth = 513;
			vheight = 133;
			vurl = 'dv_contact.php';
			break
	}
	var win = new Window({className:"alphacube", title: vtitle, width: vwidth, height: vheight, url: vurl + "?pid=" + pid});
	win.showCenter(true);
	win.setDestroyOnClose();
};

function show_pic(picpath)
{
	var win = new Window({className:"alphacube", title: "撿視圖片", width: 450, height: 450, url: picpath});
	win.showCenter(true);
	win.setDestroyOnClose();	
};


function show_info(title,pagepath,vwidth,vheight)
{
	var win = new Window({className:"alphacube", title: title, width: vwidth, height: vheight, url: pagepath});
	win.showCenter(true);
	win.setDestroyOnClose();	
};

function edit_event(tyd,evid,pid)
{
	var vtitle = '';
	var vwidth = 0;
	var vheight =0;
	var vurl = '';
	
	switch(tyd)
	{
		case 'E1':
			vtitle = '編輯學歷 - 小學，中學';
			vwidth = 513;
			vheight = 238;
			vurl = 'dve_edu.php';
			break    
		case 'E2':
			vtitle = '編輯學歷 - 高中以上';
			vwidth = 513;
			vheight = 304;
			vurl = 'dve_edu2.php';
			break
		case 'E3':
			vtitle = '編輯 - 曾經是老師';
			vwidth = 513;
			vheight = 304;
			vurl = 'dve_exp1.php';
			break
		case 'E4':
			vtitle = '編輯 - 其他經歷身分';
			vwidth = 513;
			vheight = 290;
			vurl = 'dve_exp2.php';
			break
		case 'E5':
			vtitle = '編輯 - 上傳照片';
			vwidth = 483;
			vheight = 173;
			vurl = 'dve_event_pic.php';
			break
		case 'E6':
			vtitle = '編輯 - 大事件';
			vwidth = 483;
			vheight = 188;
			vurl = 'dve_event.php';
			break
		case 'E7':
			vtitle = '編輯 - 隨便寫寫';
			vwidth = 483;
			vheight = 188;
			vurl = 'dve_notes.php';
			break
		case 'E8':
			vtitle = '編輯 - 出生資料';
			vwidth = 513;
			vheight = 133;
			vurl = 'dve_birth.php';
			break
		case 'E9':
			vtitle = '編輯 - 聯絡資料';
			vwidth = 513;
			vheight = 133;
			vurl = 'dve_contact.php';
			break
	}
	var win = new Window({className:"alphacube", title: vtitle, width: vwidth, height: vheight, url: vurl + "?pid=" + pid + "&evid=" + evid});
	win.showCenter(true);
	win.setDestroyOnClose();
};

function delpage(pid)
{
	var vtitle = '刪除小人物';
	var vwidth = 470;
	var vheight =310;
	var vurl = 'dv_delpage.php';
	
	var win = new Window({className:"alphacube", title: vtitle, width: vwidth, height: vheight, url: vurl + "?pid="+ pid});
	win.showCenter(true);
	win.setDestroyOnClose();
};