Location: PHPKode > projects > Ptk-forensics > ptk/lib/analysis_dataunit.php
<?
/*
PTK  - DFLabs
Copyright (C) 2008 - DFLabs srl - All rights reserved
hide@address.com
*/
include("header.php");
include("check_session_image.php");

$inv_token = md5(uniqid(rand(), TRUE));
$_SESSION['data_token'] = $inv_token;
?>
<link rel="stylesheet" type="text/css" href="../css/file_table.css"/>
<link rel="stylesheet" type="text/css" href="../css/keyword_table.css"/>

<div id="container_left" class="container_left" style="padding:0px; width:230px">	
		<?
		if($_SESSION['len_partitions']>1){
			?>
			<br>
			&nbsp;&nbsp;&nbsp;Partition:
			<select id="partition" name="partition" style="width: 200px; margin-left:10px">
				<option value=""></option>
				<option value="raw" onclick="ajax_request('get_allocation_list.php?tk=<?=$inv_token?>&arg1=null&arg2=0', 'allocation_list')"><?=$_SESSION['image'];?> [raw]</option>
			<?
			for($i=0;$i<$_SESSION['len_partitions'];$i++){
				?><option value="<?=$_SESSION["partition".$i."_offset"]?>" onclick="ajax_request('get_allocation_list.php?tk=<?=$inv_token?>&arg1=<?=$_SESSION["partition".$i."_offset"]?>&arg2=0', 'allocation_list')">partition-<?=$i." [".$_SESSION["partition".$i."_filesystem"]."]";?></option><?
			}
			?></select><?
		}else{
			if($_SESSION['is_partitioned']==1){
				$offset = $_SESSION["partition0_offset"];
			}else{
				$offset = 'null';
			}					
			?><input type="hidden" id="partition" value="<?=$offset;?>"><?
		}
		?>	
	<?if($_SESSION['len_partitions']>1){?>
		<div id="tab_view_left" style="margin-top:20px">
	<?}else{?>
		<div id="tab_view_left" style="margin-top:-10px">
	<?}?>
		<div class="dhtmlgoodies_aTab">		
			Sector number:
			<br><input type="text" name="sector" id="sector" style="width:200px; font-size:9pt"><br>
			Number of sectors to view:
			<br><input type="text" name="total" id="total" style="width:200px; font-size:9pt"><br><br>
			<button onclick="var offset=document.getElementById('partition').value; var sector=document.getElementById('sector').value; var total=document.getElementById('total').value; var title=sector;  if(total!=''){tovalue=parseInt(title)+parseInt(total)-1; title=title+'-'+tovalue}; if(offset==''){alert('Please, choose a partition.')}; if(sector==''){alert('Please, type a sector to view.')}; if(sector!='' && offset!=''){createNewTab('tab_view_right',title,'','get_data_unit.php?tk=<?=$inv_token?>&arg1='+offset+'&arg2='+sector+'&arg3='+total,true)}">  View  </button>
		</div>
		<div class="dhtmlgoodies_aTab">
			<div id="allocation_list">	
				<?if($_SESSION['len_partitions']>1){					
					?>
				<br>
				Select a partition to view its allocation list.
				<?}else{?>
					<script>
					ajax_request('get_allocation_list.php?tk=<?=$inv_token?>&arg1=<?=$offset;?>&arg2=0', 'allocation_list');
					</script>
				<?}?>
			</div>		
		</div>
	</div>
</div>

<div id="analysis_left_handle" onclick="switchScrollH('container_left')"></div>

<div id="container_right" style="overflow:auto">
	<div id="tab_view_right" style="margin-top:-10px">
		<div class="dhtmlgoodies_aTab">			
		</div>		
	</div>
</div>

<script type="text/javascript">
initTabs('tab_view_left',Array('Search', 'Allocation list'),0,"100%","",Array(false));
initTabs('tab_view_right',Array('Tab'),0,"100%","",Array(false));
deleteTab('Tab');
</script>
<?include("footer.php");?>
Return current item: Ptk-forensics