Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit df22ff4

Browse files
案例blog,更新模板
1 parent 5f84b91 commit df22ff4

File tree

6 files changed

+174
-132
lines changed

6 files changed

+174
-132
lines changed

‎.idea/workspace.xml‎

Lines changed: 120 additions & 120 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎php-mysql/blog/css/bootstrap.min.css‎

Lines changed: 5 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎php-mysql/blog/css/style.css‎

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
.header{
2+
height:50px;
3+
position: fixed;
4+
top: 0;
5+
background: #f5f5f5;
6+
text-align: left;
7+
padding:5px 20px ;
8+
line-height: 50px;
9+
}
10+
.site-name{
11+
font-size: 16px;
12+
font-weight: 700;
13+
}
14+
.footer{
15+
height:50px;
16+
position: fixed;
17+
bottom: 0;
18+
background: #f5f5f5;
19+
text-align: center;
20+
line-height: 50px;
21+
}

‎php-mysql/blog/footer.php‎

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,9 @@
55
* Date: 2016年11月1日
66
* Time: 23:51
77
*/
8-
//require 'class/system.php';
9-
//网站footer
10-
$footer = " <div style=\"width:100%;height:50px;position: fixed;bottom: 0;background: #f5f5f5;text-align: center;line-height: 50px;\">".
11-
SITE_NAME."&copy;2016".SITE_OWNER ."</div>";
128

9+
?>
10+
<!--网站footer-->
11+
<div class="footer col-md-12">
12+
&copy; 2016 <?php echo SITE_OWNER ?>
13+
</div>

‎php-mysql/blog/header.php‎

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,11 @@
66
* Time: 23:51
77
*/
88
//网站header
9-
$header = " <div style=\"width:100%;height:50px;position: fixed;top: 0;background: #f5f5f5;text-align: left;padding:5px 20px ;line-height: 50px;\">".
10-
SITE_NAME ."</div>";
9+
?>
10+
<div class="header col-md-12">
11+
<div class="col-md-10 col-md-offset-1">
12+
<span class="site-name">
13+
<?php echo SITE_NAME ?>
14+
</span>
15+
</div>
16+
</div>

‎php-mysql/blog/index.php‎

Lines changed: 15 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,19 @@
66
* Time: 23:01
77
*/
88
require 'class/system.php';
9-
require 'header.php';
10-
require 'footer.php';
119
//主页
12-
echo "<html style='padding: 0;margin: 0'><body style='padding: 0;margin: 0'>";
13-
echo $header;
14-
echo $footer;
15-
echo "</html></body?";
10+
?>
11+
<!DOCTYPE html>
12+
<html lang="en">
13+
<head>
14+
<meta charset="UTF-8">
15+
<title><?php echo SITE_NAME ?></title>
16+
<link rel="stylesheet" href="css/bootstrap.min.css">
17+
<link rel="stylesheet" href="css/style.css">
18+
</head>
19+
<body>
20+
<?php include 'header.php'; ?>
21+
22+
<?php include 'footer.php'; ?>
23+
</body>
24+
</html>

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /