HEX
Server: Apache/2.4.49 (FreeBSD) OpenSSL/1.0.2s-freebsd PHP/5.6.36
System: FreeBSD hosting.icon.bg 11.3-RELEASE-p13 FreeBSD 11.3-RELEASE-p13 #0: Tue Sep 1 06:56:51 UTC 2020 root@amd64-builder.daemonology.net:/usr/obj/usr/src/sys/GENERIC amd64
User: ftpuser (1002)
PHP: 5.6.36
Disabled: NONE
Upload Files
File: /hosting/kak.bg/web/wp-content/plugins/adchief_traffic_connector/tm-admin.php
<?php 
$msg = ''; 
if(isset($_POST['aaSave'])) {
	if($_POST['aaCode']!='') { 
		$ccd = preg_replace('/[^A-Za-z0-9\-]/', '', stripslashes($_POST['aaCode']));
		update_option( 'ads_atmcd', $ccd);
		update_option( 'ads_atmcdchk', $_POST['aaCheck'] );
		$aaCode = get_option( 'ads_atmcd');
		
	}
	else {
		$msg ='Please provide the code first!';
	}	
}
$setStatus = get_option('ads_atmcdchk');
if($setStatus=='') {
	$setStatus = 1;
}
?>	
	<div class="wrap saap_admin">
		<div class="clear_both"></div> 
		<h2>Adchief Connector</h2>
		<div style="clear:both; height:10px"></div>
		
		<div class="subtitle"><div class="view_title">Basic Settings</div></div>		
		
		<div class="section">		
			<p>
				Please submit the code as provided from <a href="http://adchief.io/get-plugin" target="_blank">adchief.io</a>. 
				<br/><br/>
				<?php if($msg!='') {?>
					<span class="aat_error"><?php echo $msg;?></span>
				<?php } ?>
				<form name="adacode" id="adacode" action="#" method="post">
				<table class="form-table">
					<tbody>
						
					<tr class="form-field">
						<th scope="row"><label for="first_name">Code <span class="description">(required)</span></label></th>
						<td><input type="text" class="sm" name="aaCode" id="aaCode" value="<?php echo get_option( 'ads_atmcd');?>" placeholder="######" /></td>
					</tr>
					<tr class="form-field">
						<th scope="row"><label for="last_name">Tracking Status</label></th>
						<td>
							<input type="radio" name="aaCheck" id="aaCheck" <?php if($setStatus==1) {?>checked="checked"<?php } ?>  value="1" />
								<span>On</span>
							<input type="radio" name="aaCheck" id="aaCheck" <?php if($setStatus==0) {?>checked="checked"<?php } ?> value="0"/>
								<span>Off</span>
						</td>
					</tr>
					</tbody>
				</table>
				<p class="submit"><input type="submit" name="aaSave" id="aaSave" class="button button-primary" value="Save"></p>
				</form>
				
			</p>
		</div>
	</div>