<?php
	$actions = array('change');
	(key_exists('action', $_GET) && $_GET['action']<>'' && in_array($_GET['action'], $actions) && session_is_registered('mobile_logged_in')) ? $action = $_GET['action'] : $action = '';
	
	if($action=='change')
	{
		(key_exists('mobil', $_POST) && $_POST['mobil']<>'') ? $mobil = $_POST['mobil'] : $mobil = '';
		if($mobil<>'')
		{
			$query = "UPDATE mobile_users SET moj_mobil='$mobil' WHERE ID='".$_SESSION['my_id']."' limit 1";
			$dba->ExecuteQuery($query);
			$_SESSION['mobile_moj_mobil'] = $mobil;
		}
	}
?>