forked from lkorth/php-form-builder-class
-
Notifications
You must be signed in to change notification settings - Fork 0
/
header.php
85 lines (77 loc) · 3.59 KB
/
header.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
<?php
$cwd = str_replace("\\", "/", getcwd());
if(strpos($cwd, "/examples") !== false) {
$pathPrefix = "../";
$examplePathPrefix = "";
}
else {
$pathPrefix = "";
$examplePathPrefix = "examples/";
}
$version = file_get_contents($pathPrefix . "version");
function prettyprint($code) {
echo '<pre class="prettyprint linenums">', str_replace("\t", str_repeat(" ", 4), htmlspecialchars($code)), '</pre>';
}
?>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>PHP Form Builder Class</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link href="<?php echo $pathPrefix; ?>PFBC/Resources/bootstrap/css/bootstrap.min.css" rel="stylesheet">
<style type="text/css">
body {
padding-top: 60px;
padding-bottom: 40px;
}
.sidebar-nav {
padding: 9px 0;
}
</style>
<link href="<?php echo $pathPrefix; ?>PFBC/Resources/bootstrap/css/bootstrap-responsive.min.css" rel="stylesheet">
<link href="<?php echo $pathPrefix; ?>prettify/prettify.css" rel="stylesheet">
<!-- HTML5 shim, for IE6-8 support of HTML5 elements -->
<!--[if lt IE 9]>
<script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
<script type="text/javascript" src="<?php echo $pathPrefix; ?>PFBC/Resources/jquery.min.js"></script>
<script src="<?php echo $pathPrefix; ?>PFBC/Resources/bootstrap/js/bootstrap.min.js"></script>
<script src="<?php echo $pathPrefix; ?>prettify/prettify.js"></script>
</head>
<body onload="prettyPrint()">
<div class="navbar navbar-inverse navbar-fixed-top">
<div class="navbar-inner">
<div class="container-fluid">
<a class="brand" href="<?php echo $pathPrefix; ?>index.php">PHP Form Builder Class</a>
<div class="nav-collapse collapse">
<p class="navbar-text pull-right">
Sponsored by <img src="http://www.imavex.com/schemes/IMAVEX.COM/images/imavex-logo.png" alt="imavex" style="height: 25px; margin-top: -3px; cursor: pointer;" onclick="window.location = 'http://www.imavex.com/';"/>
</p>
</div>
</div>
</div>
</div>
<div class="container-fluid">
<div class="row-fluid">
<div class="span3">
<div class="well sidebar-nav">
<ul class="nav nav-list">
<li><a href="http://code.google.com/p/php-form-builder-class/downloads/list">Download PFBC <?php echo $version; ?></a></li>
<li><a href="<?php echo $pathPrefix; ?>index.php#whats-new-in-3x">What's New in 3.x</a></li>
<li><a href="<?php echo $pathPrefix; ?>index.php#getting-started">Getting Started</a></li>
<li><a href="http://groups.google.com/group/php-form-builder-class/">Mailing List</a></li>
<li><a href="http://code.google.com/p/php-form-builder-class/issues/list">Bug Tracker</a></li>
<li class="nav-header">Examples</li>
<?php
$script = basename($_SERVER["PHP_SELF"]);
?>
<li<?php if($script == "form-elements.php") echo ' class="active"';?>><a href="<?php echo $examplePathPrefix; ?>form-elements.php">Form Elements</a></li>
<li<?php if($script == "html5.php") echo ' class="active"';?>><a href="<?php echo $examplePathPrefix; ?>html5.php">HTML5</a></li>
<li<?php if($script == "views.php") echo ' class="active"';?>><a href="<?php echo $examplePathPrefix; ?>views.php">Views</a></li>
<li<?php if($script == "validation.php") echo ' class="active"';?>><a href="<?php echo $examplePathPrefix; ?>validation.php">Validation</a></li>
<li<?php if($script == "ajax.php") echo ' class="active"';?>><a href="<?php echo $examplePathPrefix; ?>ajax.php">Ajax</a></li>
</ul>
</div>
</div>
<div class="span9">