Code for Embedding TiltViewer example page

Home | Instructions | Source code

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
<html xmlns="" xml:lang="en">
    <meta http-equiv="content-type" content="text/html; charset=utf-8" />
      This block of php code allows svManager to set the background color and page title.
      $preferences = file_get_contents('preferences.txt');
      $preferences = unserialize($preferences);
      $title = htmlspecialchars($preferences['htmlTitle'], ENT_QUOTES, 'UTF-8');
      $backgroundColor = substr($preferences['backgroundColor'], 2, strlen($preferences['backgroundColor']) - 2);
      In this example, the page title is not set automatically
      print '<title>'.$title.'</title>';
    <link rel="stylesheet" type="text/css" href="stylesheet.css" />
    <title>Advanced svManager and SimpleViewer 2</title>
    <script type="text/javascript" src="svmanager/g1/swfobject.js"></script>
    <!-- I am linking to the swfobject script in the g1 gallery. You could also get it from the web like this:
    <script type="text/javascript" src=""></script>
		<script type="text/javascript">
			var flashvars = {};
			flashvars.galleryURL = "gallery.xml";
			var params = {};			
			params.allowfullscreen = true;
			params.allowscriptaccess = "always";
			params.bgcolor = "<?php echo $backgroundColor; ?>";
			swfobject.embedSWF("/svmanager/g1/simpleviewer.swf", "flashContent", "800", "600", "9.0.124", false, flashvars, params);

    <style type="text/css">	    
  <body onload="this.focus();">
    <div id="wrapper">
      <h1>Embedding an svManager/SimpleViewer 2 gallery in your home page</h1>
      <p>Home | <a href="instructions.php">Instructions</a> | <a href="source.php">Source code</a></p>
      <p style="background-color: #FFFF99; padding: 10px 0 10px 0">NOTE: SimpleViewer has been <a href="">upgraded to version 2.0</a>. This document applies to <strong>SimpleViewer 2.0</strong>. Other examples are available for <a href="">SimpleViewer&nbsp;1.9</a> and <a href="">TiltViewer</a>. AutoViewer and PostcardViewer work in a similar way to the TiltViewer example.</p>
      <p>This example is aimed at people who are already familiar with <a href="">SimpleViewer</a> and <a href="">svManager</a>.</p>
      <p><a href="instructions.php">Instructions</a> are on a separate page. To see how this page works, <a href="source.php">look at the source code.</a></p>
    	<div id="flashContent">SimpleViewer requires JavaScript and the Flash Player. <a href="">Get Flash.</a>.
  	  <p>If there is anything that&rsquo;s not clear then please post a question on the <a href="">svManager forum</a>.</p>