function js_add_jquery_plugin_css($plugin, $version = "")
{
    $cached = date("YmdHis");
    $local_css = "http://" . HOST . "/sandbox/system/languages/javascript/frameworks/jquery/plugins/{$plugin}/jquery.{$plugin}.css?{$cached}";
    html_add_link_css($local_css);
}
// initilizing platform for self-contained objects
platform_launch_initialize();
define('SLIDESHOW_PATH', 'supersized/slideshow');
//PLATFORM_SANDBOX_WORKSPACE_URI
?>
<!DOCTYPE html>
<html>
<head>
<title>Photo Viewer</title>
<?php 
js_add_jquery();
// adding jquery library
js_add_jquery_ui();
// adding jquery ui library
html_add_link_css(SLIDESHOW_PATH . DS . 'css/supersized.css', 'media="screen"');
html_add_link_css(SLIDESHOW_PATH . DS . 'theme/supersized.shutter.css', 'media="screen"');
html_add_js('https://ajax.googleapis.com/ajax/libs/jquery/1.6.1/jquery.min.js');
html_add_js(SLIDESHOW_PATH . DS . 'js/jquery.easing.min.js');
html_add_js(SLIDESHOW_PATH . DS . 'js/supersized.3.2.7.min.js');
html_add_js(SLIDESHOW_PATH . DS . 'theme/supersized.shutter.min.js');
$cache_path = PLATFORM_SANDBOX_SYSTEM_CACHES_PATH . DS . 'photo';
$photo_files = find_filetype('jpg', PLATFORM_SANDBOX_WORKSPACE_PATH);
$c = 0;
?>
	
		<script type="text/javascript">
			
			jQuery(function($){
				
				$.supersized({
				
<!DOCTYPE HTML>
<html lang="en" manifest="sandbox/system/applications/browser/cache.manifest" class="js canvas canvastext geolocation history websockets video audio localstorage webworkers applicationcache">
<head>
  <title>Platform Browser [platform://platform@<?php 
echo strtolower(HOST);
?>
]</title>
  <meta name="apple-mobile-web-app-capable" content="yes">
  <meta name="apple-mobile-web-app-status-bar-style" content="default">
  <meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1">
  <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
  <?php 
html_add_link_css('http://' . HOST . '/sites/fonts/vendors/foundation-icons/foundation-icons.css?' . date('YmdHi'));
?>
  <?php 
html_add_link_css('http://' . HOST . '/sandbox/system/applications/browser/assets/css/style.css?' . date('YmdHi'));
?>
  <?php 
js_add_jquery_plugin_css("jgrowl");
?>
  <link rel="shortcut icon" href="http://<?php 
echo HOST;
?>
/sites/icons/icon_platforms.png" type="image/x-icon" />
  <!--[if lt IE 9]>
    <script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
  <![endif]-->

<?php 
js_add_jquery();
?>