How to get two values in AJAX with same condition?

How to get two values in AJAX with same condition?

How to get two values in ajax :

Source-code :

     1) database.php

  1. <?php
  2. $servername = "localhost";
  3. $username   = "root";
  4. $password   = "";
  5. $dbname = "kolupadi_extension_order";

  6. $conn = mysqli_connect($servername, $username, $password, $dbname );

  7. if(!$conn)
  8. {
  9. echo "Try after Sometimes" .mysqli_connect_error();
  10. }

  11. ?>

       2)  upgrade.php (Form)

                    https://paste.ofcode.org/Wi8Y3qZftCpSQEKYgjxe9k

       3) ajax_data.php :



FYI => The column return the price, same how can i return my shipping weight, 

I have both price and shipping_weight,

Now my price ajax look like :

  1. if(isset($_POST['old']) && isset($_POST['new'])){
  2. $old = $_POST['old'];
  3. $new = $_POST['new'];

  4. if($old=='three_compact'&&$new=='five_compact'){  // 6250111

  5. echo "2500";
  6. }

  7. elseif($old=='three_compact'&&$new=='five_regular') //6250112
  8. {
  9. echo "2500";
  10. }
  11.        

From the above code return price as 2500 and i need to return also shipping_weight as 10.

How to pass two field values in same ajax condition?