| Server IP : 127.0.0.1 / Your IP : 216.73.216.48 Web Server : Apache/2.4.58 (Win64) OpenSSL/3.1.3 PHP/8.2.12 System : Windows NT DESKTOP-3H4FHQJ 10.0 build 19045 (Windows 10) AMD64 User : win 10 ( 0) PHP Version : 8.2.12 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : D:/xampp/htdocs-coblaa/sn_re/ |
Upload File : |
<div style="display:none;">
<?php
//$message_text = mysqli_real_escape_string($con,$message_text);
include('db.php');
session_start();
$status = $_GET['status'];
//////////////////////////////////////////////////////////
$curr_day = date("d");
$curr_month = date("m");
$curr_year = date("Y");
///////////////////////////////////////////////////////////////
$user_ip = getenv('REMOTE_ADDR');
$geo = unserialize(file_get_contents("http://www.geoplugin.net/php.gp?ip=$user_ip"));
$city = $geo["geoplugin_city"];
$region = $geo["geoplugin_regionName"];
$country = $geo["geoplugin_countryName"];
/*echo"$user_ip";
echo "City: ".$city."<br>";
echo "Region: ".$region."<br>";
echo "Country: ".$country."<br>";
/*
geoplugin_request
geoplugin_status
geoplugin_credit
geoplugin_city
geoplugin_region
geoplugin_areaCode
geoplugin_dmaCode
geoplugin_countryCode
geoplugin_countryName
geoplugin_continentCode
geoplugin_latitude
geoplugin_longitude
geoplugin_regionCode
geoplugin_regionName
geoplugin_currencyCode
geoplugin_currencySymbol
geoplugin_currencySymbol_UTF8
geoplugin_currencyConverter
*/
if($status=='terminate_contract')
{
$id_user = $_GET['id_user'];
$update_tenant = "update sn_tenanttb set aggrement_status='Expired'where id='$id_user' ";
$run_update_tenant = mysqli_query($con,$update_tenant);
}
//////////////////////////////////////////////////////////////
?></div>
<?php
if($status == 'disp_water_pend_amt')
{
$my_id = $_GET['my_id'];
/*$get_pend_water_amt = "select * from water_bank where my_id ='$my_id' ";
$run_get_pend_water_amt = mysqli_query($con,$get_pend_water_amt);
while($row_get_pend_water_amt = mysqli_fetch_array($run_get_pend_water_amt))
{
$pend_amount = $row_get_pend_water_amt['pend_amount'];
echo"UGX: $pend_amount";
}*/
$get_pend_water_amt = "select * from previous_meter_readingtb where user_id ='$my_id' ";
$run_get_pend_water_amt = mysqli_query($con,$get_pend_water_amt);
while($row_get_pend_water_amt = mysqli_fetch_array($run_get_pend_water_amt))
{
$pend_amount = $row_get_pend_water_amt['pending_amount'];
echo"UGX: $pend_amount";
}
}
//$insert_prev_reading ="insert into previous_meter_readingtb(user_id,previous_reading,pending_amount,cur_date) values('$user_id','$cur_meter_reading','$total_due',CURDATE() )";
//$run_insert_prev_reading = mysqli_query($con,$insert_prev_reading);
?>