Example #1
0
 public function __construct()
 {
     parent::__construct();
     $this->session = Session::instance();
     require Kohana::find_file('vendor', 'classTextile');
     require Kohana::find_file('vendor', 'Markdown');
     $this->auth = Auth::instance();
     $this->access = Access::instance();
     $this->filebrowser = Filebrowser::instance();
     $this->filekind = FileKind::instance();
     Subfolio::set_filebrowser($this->filebrowser);
     Subfolio::set_auth($this->auth);
     Subfolio::set_template($this->template);
     Subfolio::set_filekind($this->filekind);
     $this->template->site_title = Kohana::config('filebrowser.site_name');
     $this->template->page_title = "";
 }
Example #2
0
	<?php 
}
?>
	
	<?php 
if (SubfolioFiles::is_root()) {
    ?>
		<h1 class="h1_home"><?php 
    echo SubfolioTheme::get_site_title();
    ?>
</h1>
	<?php 
} else {
    ?>
		<h1 class="h1"><?php 
    echo Subfolio::current_file('filename');
    ?>
</h1> 
	<?php 
}
?>
</header>

<?php 
if (!SubfolioFiles::is_root()) {
    ?>
	<nav>
		<span class='parent_dir'><?php 
    echo SubfolioFiles::parent_link(SubfolioLanguage::get_text('parent_directory'));
    ?>
</span>
Example #3
0
<EMBED 
  src='<?php 
echo Subfolio::current_file('url');
?>
' 
  autoplay=<?php 
echo Subfolio::current_file('autoplay');
?>
  quality=high 
  width='<?php 
echo Subfolio::current_file('width');
?>
' 
  height='<?php 
echo Subfolio::current_file('height');
?>
' 
  scale='noscale' 
  TYPE='application/x-shockwave-flash' 
  PLUGINSPAGE='http://public.macromedia.com/go/getflashplayer'>
</EMBED>

<?php 
if (SubfolioTheme::get_option('display_info')) {
    require "_hideable_download_box.php";
}
Example #4
0
    ?>
			<li><?php 
    echo Subfolio::link_to(SubfolioLanguage::get_text('logout'), '/logout');
    ?>
</li>
		<?php 
}
?>

		<?php 
if (SubfolioTheme::get_option('display_send_page')) {
    $subject = "Link from " . $_SERVER["SERVER_NAME"];
    $body = Subfolio::current_url();
    ?>
			<li><?php 
    echo Subfolio::mail_to(SubfolioLanguage::get_text('sendpage'), '', $subject, $body);
    ?>
</li>
		<?php 
}
?>

		<?php 
if (SubfolioTheme::get_option('display_tiny_url')) {
    echo SubfolioTheme::get_tiny_url(SubfolioLanguage::get_text('generatetinyurl'), 'li');
}
?>

		<?php 
if (SubfolioTheme::get_option('display_collapse_header') && SubfolioTheme::get_option('display_header', true)) {
    echo SubfolioTheme::get_collapse_header_button('li');
Example #5
0
		<dt><?php 
echo SubfolioLanguage::get_text('kind');
?>
</dt><dd><?php 
echo Subfolio::current_file('kind');
?>
</dd>
		<dt><?php 
echo SubfolioLanguage::get_text('lastmodified');
?>
</dt><dd><?php 
echo Subfolio::current_file('lastmodified');
?>
</dd>
		<dt><?php 
echo SubfolioLanguage::get_text('size');
?>
</dt><dd><?php 
echo Subfolio::current_file('size');
?>
</dd>
		<dt><?php 
echo SubfolioLanguage::get_text('comment');
?>
</dt><dd><?php 
echo Subfolio::current_file('comment');
?>
</dd>
	</dl>
	
</div>
Example #6
0
<div class="standard_paragraph"> 
	<?php 
echo Subfolio::current_file('body');
?>
</div>

<?php 
if (SubfolioTheme::get_option('display_info')) {
    require "_hideable_download_box.php";
}
Example #7
0
echo SubfolioLanguage::get_text('size');
?>
</dt><dd><?php 
echo Subfolio::current_file('size');
?>
</dd>
		<dt><?php 
echo SubfolioLanguage::get_text('comment');
?>
</dt><dd><?php 
echo Subfolio::current_file('comment');
?>
</dd>
	</dl>
	<p id='instructions'><?php 
echo Subfolio::current_file('instructions');
?>
</p>
	<a id="download" href="<?php 
echo Subfolio::current_file('link');
?>
?download=true" target="<?php 
echo Subfolio::current_file('target');
?>
"><?php 
echo SubfolioLanguage::get_text('downloadfile');
?>
</a>
	<!-- Link_name can be open or download. These words taken from the language file... -->
	
</div>
Example #8
0
			<div id="content">
				<?php 
if (isset($content)) {
    echo $content;
}
?>
			</div>
			<div class="clear"></div>
		</div>
		<?php 
include "footer.inc.php";
?>
	</div>

  <?php 
$ga_code = Subfolio::get_setting('google_analytics_code');
if ($ga_code != '') {
    ?>
      <script type="text/javascript">
      var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
      document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
      </script>
      <script type="text/javascript">
      try {
      var pageTracker = _gat._getTracker("<?php 
    echo $ga_code;
    ?>
");
      pageTracker._trackPageview();
      } catch(err) {}</script>
  <?php 
Example #9
0
<?php

$filename = Subfolio::current_file('filename');
$url = Subfolio::current_file('feedurl');
$count = Subfolio::current_file('count');
$cache = Subfolio::current_file('cache');
$items = SubfolioFiles::fetch_rss($url, $count, $filename, $cache);
?>
  
<div class="rss">
<?php 
foreach ($items as $item) {
    ?>
  <div class="item">
    <h2><a href="<?php 
    echo $item['link'];
    ?>
"><?php 
    echo $item['title'];
    ?>
</a></h2>
    <p><?php 
    echo $item['description'];
    ?>
</p>
  </div>
<?php 
}
?>
</div>
Example #10
0
<?php

/* Should the image be inlined or just show download info? */
$max_size = Subfolio::get_setting('display_max_filesize');
$size = Subfolio::current_file('rawsize');
if ($size > $max_size * 1024 * 1024) {
    require "_download_box.php";
} else {
    ?>
  <img width="<?php 
    echo Subfolio::current_file('width');
    ?>
" height="<?php 
    echo Subfolio::current_file('height');
    ?>
" src="<?php 
    echo Subfolio::current_file('url');
    ?>
" />
  <?php 
    if (SubfolioTheme::get_option('display_info')) {
        require "_hideable_download_box.php";
    }
}
Example #11
0
?>
  pluginspage='http://public.apple.com/quicktime/' 
  width='100%' 
  height='auto'
  scale='noscale' 
  controller='true'>
</EMBED>
This uses EMBED tag and Subfolio default src : php echo Subfolio::current_file('url') to output <?php 
echo Subfolio::current_file('url');
?>
. It's broken.

<EMBED 
  src='http://dev.subfolio.com/kittie.mp4' 
  autoplay=<?php 
echo Subfolio::current_file('autoplay');
?>
  pluginspage='http://public.apple.com/quicktime/' 
  width='100%' 
  height='auto'
  scale='noscale' 
  controller='true'>
</EMBED>
Same parameters except the video is located at http://dev.subfolio.com/kittie.mp4, outside of Subfolio 'directory' folder. Click on the play icon to launch the video.

<video width="100%" height="auto" controls autoplay>
	<!-- MP4 must be first for iPad! -->
	<source src="http://dev.subfolio.com/kittie.mp4"  type="video/mp4"  /><!-- WebKit video    -->
</video>
The video above uses the html5 VIDEO tag and is located at http://dev.subfolio.com/kittie.mp4, outside of Subfolio 'directory' folder. Its width is 100% and height is set on 'auto'. Click on the play icon to launch the video.
Example #12
0
        ?>
			<a href="<?php 
        echo Subfolio::current_file('link');
        ?>
" class="btn btn_download"><?php 
        echo SubfolioLanguage::get_text('viewfile');
        ?>
</a>
	<?php 
    }
}
?>
	
	<!-- Minisite -->
	<?php 
if (Subfolio::current_file('icon_name') == 'site') {
    ?>
 
		<a href="<?php 
    echo Subfolio::current_file('link');
    ?>
" class="btn btn_download"><?php 
    echo SubfolioLanguage::get_text('viewsite');
    ?>
</a>
	<?php 
}
?>
	
</div>
Example #13
0
 public static function set_filekind($_filekind)
 {
     Subfolio::$filekind = $_filekind;
 }