Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public function SortURL( $sortby ){
- echo __FILE__ . " on line " . __LINE__ . "<br>";
- $apiQuery = $this->APIQuery();
- if(!empty($apiQuery['sortby']) && $apiQuery['sortby'] == $sortby){
- // change polarity
- $apiQuery['sortdir'] = ($apiQuery['sortdir'] == 'asc')? 'desc' : 'asc';
- }else{
- // change sort + asc
- $apiQuery['sortBy'] = $sortby;
- $apiQuery['sortdir'] = 'asc';
- }
- return "/flight-search?" . http_build_query($apiQuery);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement