";
echo "";
// Include the page banner
$page_banner_no_bgcolor=0;
$page_banner='fishing_database.jpg';
include '../modules/page_banner.inc';
echo "\n";
echo "各位朋友你好,因為好多網友都想知道漁獲的位置,所以我們把一些潛水所得的資料都整理整理 希望各釣友潛友用來參考! 有一些地方因為是漁民的秘密排口,所以都不能公開了. 資料還會不斷update, 希望各位收穫豐富, 開心好玩! 註 : 資料包括我們所認識的釣友和潛友的漁獲, 並不全部都是我們的收穫 加上有些資料只是潛水時遇上, 並沒有捕捉, 沒有濫捕唷! 敬請留意 | 傑仔 | \n";
echo " ";
// Pre select fish
$query = "select * from `fishing_db_fish` order by `order`";
$result = mysql_query($query,$db_link)
or die("Query failed : Failed to select from fishing_db_fish");
while ($line=mysql_fetch_array($result, MYSQL_ASSOC))
$fish[count($fish)]=$line;
mysql_free_result($result);
// Fish asoc place selection
// Pre select fish
if ($fish_id!=''){
$query = "select *,b.name fish_name, c.name place_name,c.place_id place_id, b.fish_id fish_id, a.day day, a.month month, a.year year, a.time time from `fishing_db_fish` b, `fishing_db_place_asoc_fish` a, `fishing_db_place` c where a.fish_id=b.fish_id and a.place_id = c.place_id and a.fish_id='".$fish_id."' order by a.year desc, a.month desc, a.day desc, a.time desc";
$result = mysql_query($query,$db_link)
or die("Query failed 1: Failed to select from fishing_db_search_result");
while ($line=mysql_fetch_array($result, MYSQL_ASSOC)){
$search_result_id=count($search_result);
$search_result[$search_result_id]=$line;
if ($line['public']==0 && $_SESSION["user"]["user_id"]!="1" && $_SESSION["user"]["user_id"]!="2")
$search_result[$search_result_id]['place_name']="秘位";
// Plot data
$tag=strpos($line['quantity'],'(');
if ($tag==0)
$tag=1;
$increment=substr($line['quantity'],0,$tag);
$fishing_ydata[$line['month']-1]=$fishing_ydata[$line['month']-1]+(int)$increment;
}
mysql_free_result($result);
$query = "select * from `fishing_db_fish` where fish_id='".$fish_id."'";
$result = mysql_query($query,$db_link)
or die("Query failed: Failed to select from fishing_db_fish");
while ($line=mysql_fetch_array($result, MYSQL_ASSOC))
$select_target_info=$line;
mysql_free_result($result);
}else{ // Pre select place
// Select sub-places
place_sub_path($place_id,$db_link);
$place_id_list[count($place_id_list)]=$place_id;
// Retrieve place_asoc_fish records for each place in the place list
$query = "select *,b.name fish_name, c.name place_name,c.place_id place_id, b.fish_id fish_id, a.day day, a.month month, a.year year, a.time time from `fishing_db_fish` b, `fishing_db_place_asoc_fish` a, `fishing_db_place` c where a.fish_id=b.fish_id and a.place_id = c.place_id and (";
for ($i=0 ; $i";
// Plot data
$tag=strpos($line['quantity'],'(');
if ($tag==0)
$tag=1;
$increment=substr($line['quantity'],0,$tag);
$fishing_ydata[$line['month']-1]=$fishing_ydata[$line['month']-1]+(int)$increment;
}
mysql_free_result($result);
$query = "select * from `fishing_db_place` where place_id='".$place_id."'";
$result = mysql_query($query,$db_link)
or die("Query failed: Failed to select from fishing_db_place");
while ($line=mysql_fetch_array($result, MYSQL_ASSOC))
$select_target_info=$line;
if ($select_target_info['public']==0 && $_SESSION["user"]["user_id"]!="1" && $_SESSION["user"]["user_id"]!="2") // If it is a private place
$select_target_info['name']="秘位";
mysql_free_result($result);
}
// Place pre select
$heretext=<<
\n";
echo " \n";
// Google Map
?>
// Search fish results
if ($place_id!='99999'){
if ($fish_id!="") //Select by fish name
title_line("魚類 : ".$select_target_info['name']." 搜尋結果","select_target_info");
else
title_line("地點 : ".$select_target_info['name']." 搜尋結果","select_target_info");
if (count($search_result)>0){
echo "\n";
echo "";
if ($fish_id!='' && $select_target_info['photo'] ==1)
echo " | ";
echo " | ";
echo " ";
echo " \n";
echo "\n";
echo "";
echo "地點 | ";
echo "魚類 | ";
echo "時間 | 數量 | 方法 | 日記 | ";
echo " ";
for ($i=0 ; $i\n";
$color_flag=2;
}
else{
echo "\t\n";
$color_flag=1;
}
echo "";
place_path($search_result[$i]['place_id'],$db_link,$server_path);
echo " | ";
echo "".$search_result[$i]['fish_name']." | \t";
echo "";
if ($search_result[$i]['day']!=0)
echo $search_result[$i]['day']."-".$search_result[$i]['month']."-";
echo $search_result[$i]['year'];
if ($search_result[$i]['time']!=0)
echo " ".$search_result[$i]['time'];
echo " | ";
echo "".$search_result[$i]['quantity']." | ";
// Method
echo "";
if ($search_result[$i]['method']=='snorkeling')
echo "浮潛";
else if ($search_result[$i]['method']=='scuba diving')
echo "水肺潛水";
else if ($search_result[$i]['method']=='fishing boat')
echo "船釣";
else if ($search_result[$i]['method']=='boat dive')
echo "氣0候潛水";
else if ($search_result[$i]['method']=='fishing onshore')
echo "岸釣";
else if ($search_result[$i]['method']=='net')
echo "漁民網魚(幫忙收網)";
else if ($search_result[$i]['method']=='meet')
echo "遇上";
if ($search_result[$i]['bait']!=''){
echo " (魚餌 :";
switch($search_result[$i]['bait']){
case 1 : echo " 青蟲"; break;
case 2 : echo " 死蝦肉"; break;
}
echo ")";
}
echo " | ";
// Diary
if ($search_result[$i]['fishing_diary_id']!=0)
echo "Link to diary | ";
else
echo "/ | ";
echo " \t";
}
echo " ";
}else{
helper ("Sorry, 暫時沒有資料 ... 您有資料提供ma? 謝謝你喔!","",5);
}
}
echo "\n";
echo "";
// Place
title_line("位置搜尋","place");
$heretext=<<
\n";
echo " \n";
echo " | ";
// Fish
$fish_search_path='http://i161.photobucket.com/albums/t237/uncle_sea_hunter/';
title_line("魚類搜尋","fish");
echo "\n";
for ($i=0 ; $i";
}else if ($fish_search_count_flag==4){
$fish_search_count_flag=0;
}
if ($fish_id==$fish[$i]['fish_id']){
echo "\n";
echo "".$fish[$i]['name']." ";
}
else{
echo " | \n";
echo "".$fish[$i]['name']." ";
}
if ($fish[$i]['fish_id']==4 || $fish[$i]['fish_id']==3|| $fish[$i]['fish_id']==6|| $fish[$i]['fish_id']==12 )
echo "";
echo " | ";
if ($fish_search_count_flag==0){
echo "";
}
if ($fish_search_count_flag<4)
$fish_search_count_flag++;
}
echo " \n";
echo " | \n";
echo " | ";
// Include right panel for the fishing site
$_page_disable_fish_search=1;
$_page_disable_place_search=1;
include $server_path."/modules/fishing_right_panel.inc";
echo "";
$_PAGE['keywords_search_list_no_of_words']=4000;
$_PAGE['keywords_search_list_range_low']='START_OF_FISHING';
$_PAGE['keywords_search_list_range_high']='END_OF_FISHING';
// Inlclude the neccessary close module
include '../modules/default_close.inc';
?>