Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!doctype html>
- <html lang="en">
- <head>
- <meta charset="utf-8">
- <link rel="shortcut icon" href="{Favicon}" />
- <!--
- Family Tree Theme v1, made by hendrixrph. Please don't redistrube, remove the credit, or use as a base. Feel free to change around colors and fonts and things though.
- Special thanks to Ruby On Tails (I think?) for writing the original CSS3 Family Tree code tutorial that I used as a base.
- -->
- <title>Family Tree</title>
- <link href='http://fonts.googleapis.com/css?family=Lato' rel='stylesheet' type='text/css'>
- <link href='http://fonts.googleapis.com/css?family=Oswald:400,300' rel='stylesheet' type='text/css'>
- <link rel="stylesheet" href="css/styles.css?v=1.0">
- <style>
- * {margin: 0; padding: 0;}
- body {
- text-align:center;
- background:#333;
- font-family:"Lato", Helvetica, Arial, sans-serif;
- background-image:url(http://subtlepatterns.com/patterns/footer_lodyas.png);
- padding-top:70px;
- }
- header {
- width:100%;
- background-color:#252525;
- padding:10px 5px;
- position:fixed;
- top:0;
- z-index:100;
- height:65px;
- text-align:left;
- }
- header h1 {
- text-align:left;
- color:#F0FDFF;
- font-family:"Oswald", Helvetica, Arial, sans-serif;
- font-size:50px;
- letter-spacing:2px;
- padding-left:10px;
- position:absolute;
- left:20px;
- top:5px;
- font-weight:400;
- text-transform:uppercase;
- }
- header .nav {
- position:absolute;
- right:30px;
- top:40%;
- }
- header .nav a {
- text-decoration:none;
- color:#eee;
- text-transform:lowercase;
- font-family:"Lato", Helvetica, Arial, sans-serif;
- padding:0 10px;
- letter-spacing:2px;
- }
- .tree {
- margin:0px auto;
- display:inline-block;
- }
- .tree ul {
- padding-top:30px;
- position:relative;
- }
- .tree li {
- float:left;
- text-align:center;
- list-style-type:none;
- position:relative;
- padding:30px 10px 0 10px;
- }
- .tree li::before, .tree li::after {
- content:'';
- position:absolute;
- top:0;
- right:50%;
- width:50%;
- height:30px;
- border-top: 1px solid #ccc;
- z-index:-1;
- }
- .tree li::after {
- right:auto;
- left:50%;
- border-left: 1px solid #ccc;
- }
- .tree li:only-child::after, .tree li:only-child::before {
- display:none;
- }
- .tree li:only-child {
- padding-top:0;
- }
- .tree li:first-child::before, .tree li:last-child::after {
- border:0;
- }
- .tree li:last-child::before {
- border-right:1px solid #ccc;
- border-radius:0 10px 0 0;
- }
- .tree li:first-child::after {
- border-radius: 10px 0 0 0;
- }
- /*.tree li.lspouse::before, .tree li.lspouse::after {
- content:'';
- position:absolute;
- top:60%;
- width:30px;
- border:0;
- border-top:1px solid #ccc;
- border-radius:0;
- right:0;
- left:-20px;
- bottom:0;
- height:20px;
- }*/
- .tree ul ul::before {
- position:absolute;
- height:35px;
- border-left:1px solid #ccc;
- top:-5px;
- left:50%;
- content:'';
- }
- .tree li a {
- height:100px;
- width:100px;
- line-height:100px;
- border:1px solid #ccc;
- display:inline-block;
- border-radius:100px;
- -webkit-border-radius:100px;
- -moz-border-radius:100px;
- overflow:hidden;
- position:relative;
- z-index:5;
- }
- .tree li a span + img {
- width:100px;
- }
- .tree li a span {
- position:absolute;
- height:100px;
- width:100px;
- border-radius:100px;
- top:0;
- left:0;
- padding:0;
- margin:0;
- opacity:0;
- transition:1s all;
- /*background-color:rgba(255,255,255,0.85);
- color:#222;*/
- background-color:rgba(0,0,0,0.65);
- color:#eee;
- letter-spacing:1px;
- font-size:11px;
- display:table-cell;
- vertical-align:middle;
- text-transform:lowercase;
- }
- .tree li a span:hover {
- opacity:1;
- }
- .credit {
- position:fixed;
- bottom:10px;
- right:10px;
- padding:5px 7px;
- background-color:#222;
- color:#ccc;
- font-size:10px;
- font-family:"Lato", Helvetica, Arial, sans-serif;
- transition:0.75s all;
- }
- .credit:hover {
- color:#fff;
- }
- </style>
- <!--[if lt IE 9]>
- <script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
- <![endif]-->
- </head>
- <body>
- <header>
- <h1>Family Tree</h1>
- <div class="nav">
- <a href="#">Link 1</a>
- <a href="#">Link 2</a>
- <a href="#">Link 3</a>
- <a href="#">Link 4</a>
- </div>
- </header>
- <!--
- I apologize for all of the nested lists, it's messy but it was the only way to do this. I'm assuming that whoever is using this knows how <ul> and <li> tags work. If you don't, google can help you.
- In order to create a new level in the tree, add a <ul> tag within the <li> tag of whoever you want to be the parent. Within that <ul>, make a <li> for each sibling on that level.
- For organizational purposes, I recommend adding comments after the </li> that ends each entry with the name of the person in it. I already did that with the examples, feel free to edit those comments to start off.
- I'm really sorry that you can't add spouses yet. I'm working on that (it's very buggy right now), and will hopefully release a new version someday. Until then, I hope this can work for something.
- -->
- <div class="wrapper">
- <div class="tree">
- <ul>
- <li>
- <a href="#"><span>Alice</span><img src=""></a>
- <ul>
- <li>
- <a href="#"><span>Bob</span><img src=""></a>
- </li> <!-- End Bob -->
- <li>
- <a href="#"><span>Charlie</span><img src=""></a>
- </li> <!-- End Charlie -->
- </ul>
- </li> <!-- End Alice -->
- </ul>
- </div>
- <div class="credit">hendrixrph</div>
- </div>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment