-
Notifications
You must be signed in to change notification settings - Fork 25
/
simple-linked-tab.html
76 lines (73 loc) · 3.96 KB
/
simple-linked-tab.html
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
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Opening a Tab from another page - Accessible Tabs Example</title>
<meta name="author" content="Dirk Ginader">
<script type="text/javascript">document.documentElement.className += " js";</script>
<link rel="stylesheet" href="slidingdoors/simple-sliding-doors.css" type="text/css" media="screen">
<script src="js/jquery-1.7.min.js" type="text/javascript" charset="utf-8"></script>
<script src="js/jquery.tabs.js" type="text/javascript" charset="utf-8"></script>
<script type="text/javascript">
$(document).ready(function(){
$(".tabs").accessibleTabs({
tabhead:'h2',
fx:"fadeIn",
autoAnchor:true
});
});
</script>
</head>
<body>
<h1>Opening a Tab from another page - Accessible Tabs Example</h1>
<p><a href="simple-linked-tab-links.html">Page with example Links to the tabs</a></p>
<div class="tabs">
<h2 id="tab1">some dummy text</h2>
<div class="tabbody">
<p>Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Nullam malesuada suscipit pede. Nullam ipsum lacus, varius vel, nonummy in, consequat ut, neque. </p>
<h3>Lorem ipsum</h3>
<p>Nullam malesuada suscipit pede. Nullam ipsum lacus, varius vel, nonummy in, consequat ut, neque. Vivamus viverra. Duis dolor arcu, lacinia sit amet, sollicitudin sed, aliquet vel, quam. Pellentesque molestie laoreet tortor. Aenean quam. Pellentesque magna metus, venenatis sit amet, congue nec, dictum in, est. Aliquam nibh. </p>
</div>
<h2 id="tab2">some more dummy text</h2>
<div class="tabbody">
<p>Integer tincidunt. Cras dapibus. Vivamus elementum semper nisi. Aenean vulputate eleifend tellus. Aenean leo ligula, porttitor eu, consequat vitae, eleifend ac, enim. Aliquam lorem ante, dapibus in, viverra quis, feugiat a, tellus. Phasellus viverra nulla ut metus varius laoreet. </p>
<p>Quisque rutrum. Aenean imperdiet. Etiam ultricies nisi vel augue. Curabitur ullamcorper ultricies nisi. Nam eget dui. Etiam rhoncus. Maecenas tempus, tellus eget condimentum rhoncus, sem quam semper libero, sit amet adipiscing sem neque</p>
</div>
<h2 id="tab3">anything else</h2>
<div class="tabbody">
<p>Here could be your content</p>
</div>
</div>
<h2>Usage</h2>
<p>setting "autoAnchor" to true will make the tab widget check the url when initialized.
If the url contains an anchor pointing to one of the tabs this tab will be displayed</p>
<p>You need to make sure you give the head of the tab you want to link to an unique id:</p>
<pre><code>
<h2 <strong>id="tab1"</strong>>some dummy text</h2>
<div class="tabbody"></div>
</code></pre>
<pre><code>
$(document).ready(function(){
$(".tabs").accessibleTabs({
tabhead:'h2',
fx:"fadeIn",
<strong>autoAnchor:true</strong>
});
});
</code></pre>
<p class="about">
Want to learn more about this? <a href="http://blog.ginader.de/archives/2009/02/07/jQuery-Accessible-Tabs-How-to-make-tabs-REALLY-accessible.php">jQuery Accessible Tabs - How to make tabs REALLY accessible<br></a>
Or check out <a href="index.html">more Examples</a>
</p>
<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">
var pageTracker = _gat._getTracker("UA-299719-2");
pageTracker._initData();
pageTracker._trackPageview();
</script>
</body>
</html>