将重新排序的数组值发送到api的sanizatied值

I am getting post values in array in an order i dont want.

The order i am getting is

apipost.php?option1=1&option2=1&destination=3232323&time=201410201510

I have to post data to an api.

For posting data this is my code,definately some logic is missing.

define('API_SERVICE_URL', '//192.168.x.x/x.php');

$ch = curl_init();

curl_setopt($ch, CURLOPT_URL, API_SERVICE_URL);

curl_setopt($ch, CURLOPT_POST, 1);

curl_setopt($ch, CURLOPT_POSTFIELDS, http_build_query($parameters));

curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);

$result = curl_exec ($ch);

curl_close ($ch);

It has 4 parameters to be taken.

i have to sanitize the post values as well. Unable to work on sanitization due to the work remaining Please help as i am lost

x.php?destination=<dest>&option1=<selection1>&option2=<selection2>&time=<YYYYMMDDHHMM>

example:
x.php?destination=012121242120&option1=2&option2=3&time=201410201510