https://t.me/RX1948
Server : Apache/2.4.18 (Ubuntu)
System : Linux canvaswebdesign 3.13.0-71-generic #114-Ubuntu SMP Tue Dec 1 02:34:22 UTC 2015 x86_64
User : oppastar ( 1041)
PHP Version : 7.0.33-0ubuntu0.16.04.15
Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,
Directory :  /var/www/blue-sky.co.id/public_html/application/views/ajax/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /var/www/blue-sky.co.id/public_html/application/views/ajax/ajax_change_shipping_fee.php
<?php 

$free_shipping_type = 
$this->db->select('free_shipping_type')
->from('configuration')
->where('id_configuration',1)->get()->row()
->free_shipping_type;

$condition_freeshipping = false;

if($free_shipping_type == 'region') {
	$selected_region_province = 
	$this->db->select('*')
	->from('free_shipping_region')
	->where('configuration_id',1)
	->where('province_id',$id_province)
	->get();

	if($selected_region_province->num_rows() > 0){
		$condition_freeshipping = true; 
	}
}
  
?>

<?php $count_shipping = 0; ?>

<?php
	//convert $shipping_method_ids to array
	$shipping_method_ids_array = explode(',', $shipping_method_ids);
?>

<?php foreach ($shipping_method_ids_array as $shipping_id) : ?>

	<?php $count_shipping++ ; ?>

	<?php if($shipping_id == 2): ?>
		<?php
			//get self delivery fee from configuration table
			$this->db->select('shopdelivery_fee')->from('configuration')->where('id_configuration', 1);
			$shopdelivery_fee = $this->db->get()->row()->shopdelivery_fee;
			$shipping_name = 'Express';
			$total_shipping_fee = $shopdelivery_fee;
		?>
	
	<?php else : ?>
		<?php 
			$shipping_info = calculate_shipping_fee($shipping_id, $warehouse_id, $product_id, $id, $qty, $shipping_id_subdistrict); 
			$shipping_name = $shipping_info['shipping_name'];
			$total_shipping_fee = $shipping_info['total_shipping_fee'];

			if($shipping_id == 1){
				$shipping_name = 'Same Day'; 
			}
			if($shipping_id == 3){
				$shipping_name = 'Regular'; 
			}
			if($shipping_id == 4){
				$shipping_name = 'Next Day'; 
			}
		?>
	<?php endif; ?>	

	<?php 
		$estimated_time = '';
		switch (strtolower(trim($shipping_name))) {
			case 'express':
				$estimated_time = '1-6h';
				break;

			case 'regular':
				$estimated_time = '1-3d';
				break;

			case 'next day':
				$estimated_time = '1d';
				break;

			case 'indent':
				$estimated_time = '1-3d';
				break;

			case 'same day':
				$estimated_time = '';
				break;
			
			default:
				# code...
				break;
		}
	?>	

	<?php if($total_shipping_fee > 0 || isset($shipping_info['free_shipping_applied'])) : ?>
			
		<li>
			<?php 
			// echo $selected_shipping_method_id."<br>";
			// echo $shipping_id."<br>";
			 ?>
			<input type="radio" class="shipping_method<?= $rowid; ?>" name="shipping_method<?= $rowid; ?>" value="<?= $shipping_id; ?>" 
			<?php if($selected_shipping_method_id == $shipping_id) : ?> 
				checked 
			<?php endif; ?>	
			> <?= ucwords($shipping_name)." ".strtoupper($estimated_time); ?> 
			<?php if($condition_freeshipping == true) : ?>
				(Free)
			<?php else : ?>
				<?php if($shipping_id == 5) : ?>
					<!-- (TBC) -->
					(IDR <span id="shippingFee<?= $count_shipping; ?>"><?= number_format($total_shipping_fee); ?></span>)
				<?php else : ?>
					(IDR <span id="shippingFee<?= $count_shipping; ?>"><?= number_format($total_shipping_fee); ?></span>)
				<?php endif; ?>	
			<?php endif; ?>	
		</li>	

	<?php endif; ?>
<?php endforeach; ?>







https://t.me/RX1948 - 2025