<?php
global $fm, $config, $str, $weblinks;
$browser = strtolower($_SERVER['HTTP_USER_AGENT']);

if (strstr($browser, "iphone") !== false) {
	if ($_GET['play']) {
		$fm->sendFileToBrowser($data['filePath']);
	} else {
		header("Location: ?module=fileman&section=utils&page=file_preview&play=1&path=".$str->forURL($data['relativePath']));
	}
} else {
	require_once(gluePath($config['path']['root'], "/viewers/flv/index.php"));
}