D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
home
/
shubmkcj
/
urbane.createerp.com
/
Filename :
getCustomerAddress.php
back
Copy
<?php include 'config.php'; $id = $_GET["companyId"]; $result = "<option value=''>--Select--</option>"; $invoiceNumber = 0; $getCustomerAddress = "SELECT * FROM `contact_address` WHERE contact_id = '$id' AND is_deleted = 'NO'"; $resultGetCustomerAddress = mysqli_query($conn, $getCustomerAddress) or die("error"); if($resultGetCustomerAddress){ if(mysqli_num_rows($resultGetCustomerAddress) > 0){ while($rowGetCustomerAddress = mysqli_fetch_assoc($resultGetCustomerAddress)){ $addressId = $rowGetCustomerAddress["id"]; $address = $rowGetCustomerAddress["address"]; $city = $rowGetCustomerAddress["city"]; $state = $rowGetCustomerAddress["state"]; $country = $rowGetCustomerAddress["country"]; $result .= "<option value='".$addressId."'>".$address.", ".$city.", ".$state.", ".$country."</option>"; } } } echo $result; ?>