verschillende-tabbladen-zonder-pagina-verversen
Gesponsorde koppelingen
PHP script bestanden
Code (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
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
<html>
<head>
<title>Tabbladen</title>
<link href="tabbladen.css" rel="stylesheet" type="text/css" media="screen" />
<script type="text/javascript">
function show(id) {
for(var i=1;i <= 4;i++) {
if (id == i) {
var display = 'block';
}
else {
var display = 'none';
}
document.getElementById('tab'+i).style.display = display;
}
}
</script>
</head>
<body>
<div id="container">
<ul id="tabnav">
<li><a class="list" onmouseover="this.style.cursor='hand'" onclick="show('1');">Tabblad 1</a></li>
<li><a class="list" onmouseover="this.style.cursor='hand'" onclick="show('2');">Tabblad 2</a></li>
<li><a class="list" onmouseover="this.style.cursor='hand'" onclick="show('3');">Tabblad 3</a></li>
<li><a class="list" onmouseover="this.style.cursor='hand'" onclick="show('4');">Tabblad 4</a></li>
</ul>
<div id="tabs">
<div id="tab1">Tab 1
</div>
<div id="tab2">Tab 2
</div>
<div id="tab3">Tab 3
</div>
<div id="tab4">Tab 4
</div>
</div>
</div>
</body>
</html>
<head>
<title>Tabbladen</title>
<link href="tabbladen.css" rel="stylesheet" type="text/css" media="screen" />
<script type="text/javascript">
function show(id) {
for(var i=1;i <= 4;i++) {
if (id == i) {
var display = 'block';
}
else {
var display = 'none';
}
document.getElementById('tab'+i).style.display = display;
}
}
</script>
</head>
<body>
<div id="container">
<ul id="tabnav">
<li><a class="list" onmouseover="this.style.cursor='hand'" onclick="show('1');">Tabblad 1</a></li>
<li><a class="list" onmouseover="this.style.cursor='hand'" onclick="show('2');">Tabblad 2</a></li>
<li><a class="list" onmouseover="this.style.cursor='hand'" onclick="show('3');">Tabblad 3</a></li>
<li><a class="list" onmouseover="this.style.cursor='hand'" onclick="show('4');">Tabblad 4</a></li>
</ul>
<div id="tabs">
<div id="tab1">Tab 1
</div>
<div id="tab2">Tab 2
</div>
<div id="tab3">Tab 3
</div>
<div id="tab4">Tab 4
</div>
</div>
</div>
</body>
</html>
/* CSS pagina */
Code (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
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
#container {
float: left;
margin: 1px;
padding: 0;
height: 625px;
width: 800px;
position: relative;
background-color: #999999;
}
#tabnav {
height: 37px;
list-style-type: none;
position: relative;
padding: 0 0 0 210px;
margin: 0;
background-color: #404040;
}
#tabnav li {
float: left;
margin: 8px;
}
.list {
background: url(menubutton.gif) #fff bottom left repeat-x;
width: 80px;
display: block;
border: 1px solid #dcdce9;
color: #0d2474;
text-decoration: none;
text-align: center;
}
a:hover {
cursor: pointer;
}
#tabs {
top: 75px;
left: 25px;
width: 750px;
height: 512px;
clear: both;
display: block;
position: absolute;
background-color: #404040;
}
#tab1 {
display: block;
}
#tab2 {
display: none;
}
#tab3 {
display: none;
}
#tab4 {
display: none;
}
float: left;
margin: 1px;
padding: 0;
height: 625px;
width: 800px;
position: relative;
background-color: #999999;
}
#tabnav {
height: 37px;
list-style-type: none;
position: relative;
padding: 0 0 0 210px;
margin: 0;
background-color: #404040;
}
#tabnav li {
float: left;
margin: 8px;
}
.list {
background: url(menubutton.gif) #fff bottom left repeat-x;
width: 80px;
display: block;
border: 1px solid #dcdce9;
color: #0d2474;
text-decoration: none;
text-align: center;
}
a:hover {
cursor: pointer;
}
#tabs {
top: 75px;
left: 25px;
width: 750px;
height: 512px;
clear: both;
display: block;
position: absolute;
background-color: #404040;
}
#tab1 {
display: block;
}
#tab2 {
display: none;
}
#tab3 {
display: none;
}
#tab4 {
display: none;
}