whoami7 - Manager
:
/
proc
/
self
/
root
/
home
/
papecmvm
/
www
/
application
/
controllers
/
admin
/
Upload File:
files >> //proc/self/root/home/papecmvm/www/application/controllers/admin/Apicalls.php
<?php ob_start(); defined('BASEPATH') OR exit('No direct script access allowed'); class Apicalls extends CI_Controller { function __construct() { parent::__construct(); //$session_data=$this->session->all_userdata(); /*if(!isset($session_data['flang']) && !isset($session_data['color'])) { $this->session->set_userdata('flang', ''); $this->session->set_userdata('color', 'style'); } $this->load->dbutil(); $dbs_smarttips = $this->dbutil->list_databases(); if (!$this->dbutil->database_exists('starppld_aangadia')) { show_error("Issue with the database", 500 ); exit; }*/ $this->load->model('alldata', "model"); } public function getPincodeCity(){ echo "in function"; $BoyID=$_GET['BoyID']; $syncDateTime=$_GET['syncDateTime'];//die; $xappKey = '3UTihIfpv0RXQcGVmwCuwn23uVZR9tL7OLnaLckFw1FHsNf1zvlhrvsa5lcslL9H'; //$url='http://14.192.16.215/apibooking/api/v3/GetPincodeMaster?BoyID='+$BoyID+'&SyncDateTime='+$syncDateTime; //$url='http://c2p.gojavas.net/apibooking/api/v3/GetPincodeMaster?BoyID='+$BoyID+'&SyncDateTime='+$syncDateTime; if (!isset($url)) { // This is not cross-domain request exit; } $wildcard = FALSE; // Set $wildcard to TRUE if you do not plan to check or limit the domains $credentials = FALSE; // Set $credentials to TRUE if expects credential requests (Cookies, Authentication, SSL certificates) $allowedOrigins = array('http://14.192.16.215/apibooking/api/v3/GetPincodeMaster?BoyID='+$BoyID+'&SyncDateTime='+$syncDateTime); print $url; $allowedOrigins = array($url); //echo "------".$allowedOrigins;//die; echo "<pre>";print_r($allowedOrigins); if (!in_array($url, $allowedOrigins) && !$wildcard) { // Origin is not allowed exit; } $origin = $wildcard && !$credentials ? '*' : $url; header("Access-Control-Allow-Origin: " . $origin); if ($credentials) { header("Access-Control-Allow-Credentials: true"); } header("Access-Control-Allow-Methods: POST, GET, OPTIONS"); header("Access-Control-Allow-Headers: Origin"); header('P3P: CP="CAO PSA OUR"'); // Makes IE to support cookies // Handling the Preflight if ($_SERVER['REQUEST_METHOD'] == 'OPTIONS') { exit; } // Response header("Content-Type: application/json; charset=utf-8"); echo json_encode(array('status' => 'OK')); } }
Copyright ©2021 || Defacer Indonesia