博客园自定义样式二

样式效果:

 

步骤:

1、设置博客皮肤为:SimpleMemory

2、设置博客页面定制css样式:

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
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
/* **********************
 * 整体布局
 * **********************/
 
/* 整体布局 */
body {
background: #e6ecf0;
font-family: -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica
      Neue, PingFang SC, Hiragino Sans GB, Microsoft YaHei, sans-serif;
}
 
#home {
max-width: 1140px;
padding: 15px;
background: transparent;
box-shadow: none;
margin-top: 0;
width: auto;
}
 
#main {
margin-top: 15px;
}
 
#mainContent .forFlow {
padding-right: 20px;
}
 
/* 非阅读区域去掉白色背景 */
.newsItem,
.catListEssay,
.catListLink,
.catListNoteBook,
.catListTag,
.catListPostCategory,
.catListPostArchive,
.catListImageCategory,
.catListArticleArchive,
.catListView,
.catListFeedback,
.mySearch,
.catListComment,
.catListBlogRank,
.catList,
.catListArticleCategory {
background-color: transparent;
}
 
/* **********************
 * 博客页首
 * **********************/
 
/* 隐藏系统标题 */
#blogTitle {
display: none;
}
 
/* 顶部通告条 */
.c-notice {
padding: 10px 0;
background: tan;
font-size: 0.9em;
box-shadow: 0 2px 6px rgba(0, 0, 0, 0.16), 0 2px 6px rgba(0, 0, 0, 0.23);
font-size: 15px;
}
 
.c-notice > div {
max-width: 1140px;
margin: 0 auto;
padding: 0 15px;
}
 
.c-notice a {
color: blue;
}
 
/* 头像和社交 */
.c-portrait {
text-align: center;
padding: 50px 0;
background: #39424b;
color: #fff;
margin-bottom: -40px;
}
 
/* 头像 */
.c-portrait > img {
display: inline-block;
height: 80px;
border-radius: 50%;
}
 
/* 标题和签名 */
.c-portrait h1 {
font-size: 25px;
font-weight: bold;
margin: 5px 0;
}
 
.c-portrait h1 a {
color: #fff;
}
 
.c-portrait h2 {
font-size: 16px;
margin: 7px 0 10px;
color: #ccc;
}
 
/* 社交图标 */
.c-social a {
color: #959da5;
display: inline-block;
vertical-align: middle;
}
 
/* **********************
 * 导航栏
 * **********************/
 
#navigator {
padding: 0 10px;
border-bottom: 2px solid #ccc;
}
 
#stats_article_count {
display: none;
}
 
/* **********************
 * 侧边栏
 * **********************/
 
#sideBar {
width: 250px;
margin-top: 0;
}
 
#sideBar a {
color: inherit;
}
 
/* 隐藏侧边公告标题 */
.newsItem .catListTitle {
display: none;
}
 
/* 增加列表项间距 */
.sidebar-block li {
margin-bottom: 5px;
}
 
/* **********************
 * 文章列表
 * **********************/
 
/* 文章列表 */
#topics .postTitle {
font-size: 28px;
margin: 35px 0 30px;
padding-left: 0;
}
 
#mainContent .day {
padding: 15px 20px;
background: #fff;
}
 
#mainContent .day .postTitle a {
display: inline-block;
}
 
/* **********************
 * 文章详情
 * **********************/
 
pre {
margin-bottom: 1.35em;
}
 
pre code {
padding: 10px 16px !important;
}
 
.post {
background: #fff;
padding: 0 60px 60px;
box-shadow: 0 2px 6px rgba(100, 100, 100, 0.3);
}
 
/* 文章标题 */
.postTitle {
border-left: 8px solid #21759b;
margin-bottom: 5px;
font-weight: bold;
line-height: 1;
box-sizing: border-box;
}
 
.postTitle a:hover {
margin-left: 0;
}
 
/* 去除首行缩进 */
.postBody p,
.postCon p {
text-indent: 0;
}
 
/* 重写引用块样式 */
.postBody blockquote {
min-height: auto;
border-top: none;
border-bottom: none;
border-right: none;
padding: 0 0 0 1em;
}
 
/* 增加底部留白 */
#cnblogs_post_body {
padding-bottom: 5px;
}
 
/* 防止图片溢出 */
#cnblogs_post_body img {
max-width: 100%;
}
 
/* 文章底部信息 */
.postDesc {
margin-top: 0;
}
 
/* **********************
 * 评论
 * **********************/
 
#comment_form_container .comment_textarea {
width: 100%;
}
 
.comment_vote {
padding-right: 2px;
font-size: 14px;
margin-top: 10px;
}
 
.comment_vote a.comment_digg {
color: #f80;
}
 
.feedbackItem {
margin: 20px 0 25px;
background: #fff;
padding: 10px 15px;
}
 
.feedbackCon {
font-size: 13px;
border-bottom: 0;
padding: 10px 5px 0 5px;
text-align: justify;
}
 
/* **********************
 * 文章评价
 * **********************/
 
#div_digg {
position: fixed;
right: 30px;
bottom: 50px;
background: #fff;
padding: 20px 20px 15px;
border-radius: 5px;
border: 1px solid #888;
box-shadow: 0 0 0 5px rgba(0, 0, 0, 0.3);
}
 
/* **********************
 * 隐藏广告
 * **********************/
 
#ad_t2,
#opt_under_post,
.c_ad_block,
#under_post_news,
#under_post_kb {
display: none !important;
}
 
/* **********************
 * 适配手机
 * **********************/
 
@media (max-width: 767px) {
#home {
padding-left: 0;
padding-right: 0;
}
#div_digg {
width: auto;
padding: 0;
right: -25px;
bottom: 3px;
box-shadow: none;
}
#div_digg .buryit {
display: none;
}
#mainContent .forFlow {
padding-right: 0;
}
#mainContent .post {
padding: 0 20px;
}
 
#sideBar,
#blog-comments-placeholder {
padding: 0 15px;
}
}

  3、写入博客侧边栏公告

<p style="margin-bottom:15px;line-height:2">
  QQ号:<b style="color:#1aad19;font-size:16px;">648651677</b>(问题请备注博客园昵称)
<br />
  所在地:广州
</p>

4、写入页首html

复制代码
<div class="c-notice">
<div>
    这里是你的通告内容
</div>
</div>

<div class="c-portrait">
<img src="https://images.cnblogs.com/cnblogs_com/zhoulei0517/1778955/o_200603074913%E5%A4%B4%E5%83%8F.jpg" alt="" />

<h1><a href="https://www.cnblogs.com/zhoulei0517/">楠神</a></h1>
<h2>见天地,见众生,见自己。</h2>

<div class="c-social">
<!-- 这里放你所拥有的社交图标 -->
</div>
</div>
复制代码

 

posted @   壹-ZL  阅读(176)  评论(0编辑  收藏  举报
编辑推荐:
· SQL Server 2025 AI相关能力初探
· Linux系列:如何用 C#调用 C方法造成内存泄露
· AI与.NET技术实操系列(二):开始使用ML.NET
· 记一次.NET内存居高不下排查解决与启示
· 探究高空视频全景AR技术的实现原理
阅读排行:
· 阿里最新开源QwQ-32B,效果媲美deepseek-r1满血版,部署成本又又又降低了!
· 单线程的Redis速度为什么快?
· SQL Server 2025 AI相关能力初探
· AI编程工具终极对决:字节Trae VS Cursor,谁才是开发者新宠?
· 展开说说关于C#中ORM框架的用法!
点击右上角即可分享
微信分享提示