diff --git a/app/destinations/destinations.php b/app/destinations/destinations.php index bafcc472bb..08636935f4 100644 --- a/app/destinations/destinations.php +++ b/app/destinations/destinations.php @@ -17,7 +17,7 @@ The Initial Developer of the Original Code is Mark J Crane - Portions created by the Initial Developer are Copyright (C) 2008-2020 + Portions created by the Initial Developer are Copyright (C) 2008-2021 the Initial Developer. All Rights Reserved. Contributor(s): @@ -97,7 +97,7 @@ } //set the type - switch ($_GET['type']) { + switch ($_REQUEST['type']) { case 'inbound': $destination_type = 'inbound'; break; case 'outbound': $destination_type = 'outbound'; break; case 'local': $destination_type = 'local'; break; @@ -140,7 +140,8 @@ //prepare to page the results $rows_per_page = ($_SESSION['domain']['paging']['numeric'] != '') ? $_SESSION['domain']['paging']['numeric'] : 50; - $param = "&search=".$search; + $param = "&search=".urlencode($search); + $param .= "&type=".$destination_type; if ($_GET['show'] == "all" && permission_exists('destination_all')) { $param .= "&show=all"; } @@ -215,7 +216,8 @@ echo button::create(['type'=>'button','label'=>$text['button-show_all'],'icon'=>$_SESSION['theme']['button_icon_all'],'link'=>'?type='.urlencode($destination_type).'&show=all'.($search != '' ? "&search=".urlencode($search) : null)]); } } - echo ""; + echo " \n"; + echo " "; echo button::create(['label'=>$text['button-search'],'icon'=>$_SESSION['theme']['button_icon_search'],'type'=>'submit','id'=>'btn_search','style'=>($search != '' ? 'display: none;' : null)]); echo button::create(['label'=>$text['button-reset'],'icon'=>$_SESSION['theme']['button_icon_reset'],'type'=>'button','id'=>'btn_reset','link'=>'destinations.php','style'=>($search == '' ? 'display: none;' : null)]); if ($paging_controls_mini != '') { @@ -233,8 +235,9 @@ echo $text['description-destinations']."\n"; echo "

\n"; - echo "
\n"; + echo "\n"; echo "\n"; + echo "\n"; echo "\n"; echo "\n";