function insertComapnyCrisisDate()
{
    define("YEAR_INDEX", 1);
    define("MONTH_INDEX", 2);
    $insert_value = $_GET['selectedInsertItem'];
    $company_id = $insert_value[COMPANY_ID_INDEX];
    // 檢查id是否有公司基本資料存在於資料庫, 若不存在則跳出
    if (checkCompany(TAIWAN, $company_id)) {
        // 檢查該id是否有危機發生日資料存在於資料庫, 若存在則跳出
        if (!checkCompany($GLOBALS['tableName'], $company_id)) {
            $date_value = $insert_value[YEAR_INDEX] . "." . $insert_value[MONTH_INDEX];
            // 2014.11
            // 組成新增字串
            $table_name = "company_financial_crisis";
            $insert_value_str = '(`company_id`, `crisis_date`) VALUES ("' . $company_id . '","' . $date_value . '")';
            // 新增單筆公司危機發生日資料
            $GLOBALS['dbc_object']->insertData($table_name, $insert_value_str);
            // showInsertMessage(INSERT_SUCCESS);
        } else {
            showInsertMessage(EXISTED_CRISIS_DATE);
            // 該公司的危機發生日資料已存在於資料庫中
        }
    } else {
        showInsertMessage(NO_COMPANY_DATA);
        // 該公司代號的公司不存在
    }
}
	<fb:add-section-button section="profile" /> <fb:add-section-button section="info" />
	<fb:prompt-permission perms="email">Click Here to allow us to send you Email</fb:prompt-permission>
</div>
<a href="/jewishdates/">Jewish Dates</a> >>
<a href="/jewishdates/moreDates/actions.php?uid=<?php 
echo $user;
?>
">
	<fb:name uid="<?php 
echo $user;
?>
" possessive="true" capitalize="true" linked="false"/> List
</a>
<br /><br />
	<?php 
showInsertMessage($insertedRecord);
?>
<h1><fb:name uid="<?php 
echo $user;
?>
" possessive="true" capitalize="true" /> Important Dates</h1>
<a href='?action=new'>Create New</a>

		<table>
			<thead>
				<tr>
					<th>Title</th><th>Original Date</th><th>Hebrew Date</th><th>Next Occurance</th>
				</tr>
			</thead>
<?php 
foreach ($records as $rec) {