分享
 
 
 

X-Space应用技巧:与论坛保持统一风格

王朝other·作者佚名  2008-05-30
窄屏简体版  字體: |||超大  

X-Space应用技巧:如何与论坛保持统一风格?

与Discuz!论坛无缝融合是X-Space个人门户系统的特色之一,很多站长管理员为了方便用户浏览使用,加强用户的记忆,统一了论坛与个人门户的风格。比如,这个日光海岸( http://www.sunschina.com),他们的论坛与个人门户的背景、页头做了统一修饰,在访问的时候,就不至于造成在两个网站之间跳转的感觉。

很多用户站长很羡慕这种统一的风格,却不知道该如何去做。我们就以“日光海岸”做参考,进行实例修改。( 提示:在更改之前请备份“supesite/templates/default”下所有文件)。

一、给X-Space首页的顶部加上自定义导航条

1、这是X-Space安装后的默认首页。

图片1

图片2

2、用记事本或编辑器打开 “supesite/templates/default/header.html.php”文件,在“header.html.php”中的第18行之后加入如下代码:

<div align="right" style="background-color:#07b8ff;padding-bottom:5px; padding-top:5px; padding-right:17px;color:#FFFFFF">

<table border="0" cellpadding="0" cellspacing="0">

<tr>

<td width="11" height="22"><img src="http://www.sunschina.com/space/images/sunpp/sunpp_ban_bg1.gif" align="absmiddle" /></td>

<td bgcolor="#FFFFFF" style="padding-left:5px; padding-right:5px"><a href="/index.php">&raquo;日光海岸首页</a> | <a href="/space">个人空间</a> | <a href="/space/action/blog">日志</a> | <a href="/space/action/image">相册</a> | <a href="/bbs/school.php">学校</a> | <a href="http://www.sunschina.org" target="_blank">会员服务中心</a> | <a href="/bbs/index.php">论坛</a> </td>

<td width="11" height="22"><img src="http://www.sunschina.com/space/images/sunpp/sunpp_ban_bg2.gif" align="absmiddle" /></td>

</tr>

</table>

</div>

3、保存该文件,然后刷新X-Space首页。可以看到X-Space的首页风格已经发生变化,上部的导航条已经按照我们的设计加入进来。

二、给X-Space首页顶部外围加上自定义样式

1:用记事本或编辑器打开 “supesite/templates/default/header.html.php”文件,在“header.html.php”中的第18行之后加入如下代码“

<table width="100%" border="0" cellpadding="0" cellspacing="0" bgcolor="#07b8ff">

<tr>

<td width="15">&nbsp;</td>

<td align="center">

<table width="100%" border="0" cellspacing="0" cellpadding="0" align="center">

<tr>

<td width="10%" height="20" style="padding-left:5px"><img src="http://www.sunschina.com/space/images/sunpp/logo_new.gif"></td>

<td width="90%" align="right" valign="top">&nbsp;</td>

</tr>

</table></td>

<td width="15">&nbsp;</td>

</tr>

</table>

<table width="100%" border="0" cellpadding="0" cellspacing="0">

<tr>

<td width="30"><img src="http://www.sunschina.com/space/images/sunpp/indexleft.gif" width="30" height="60"></td>

<td align=center background="http://www.sunschina.com/space/images/sunpp/indexbg.gif"><a href="index.php"></a>

<table width="100%" border="0" cellspacing="0" cellpadding="0">

<tr>

<td align=left><table width="98%" border="0" align="center" cellpadding="2" cellspacing="0">

<tr>

<td align="center" valign="middle">

</td>

</tr>

</table></td>

</tr>

</table>

<table width="100%" border="0" cellspacing="0" cellpadding="0">

<tr></tr>

</table> </td>

<td width="30"><img src="http://www.sunschina.com/space/images/sunpp/indexright.gif" width="30" height="60"></td>

</tr>

</table>

<table width="100%" border="0" cellspacing="0" cellpadding="0">

<tr>

<td width="26" height="182" valign="top" background="http://www.sunschina.com/space/images/sunpp/leftbg.gif"><img src="http://www.sunschina.com/space/images/sunpp/left.gif" width="26" height="355"></td>

<td bgcolor="#FFFFFF">

<table MAINTABLEBGCODE width="MAINTABLEWIDTH" cellpadding="MAINTABLESPACE" cellspacing="0" border="0" align="center">

<tr><td>

2、保存该文件,然后刷新X-Space首页

图片3

三、为X-Space首页页面底部加上自定义代码

1:用记事本或编辑器打开 “supesite/templates/default/header.html.php”文件,在“header.html.php”中的第13行,标记上方添加外框封闭代码:“

</td></tr>

<tr><td style="padding: BORDERWIDTH">

<br /></td>

</tr></table>

</td>

<td width="23" height="182" valign="top" background="http://www.sunschina.com/space/images/sunpp/rightbg.gif"><img src="http://www.sunschina.com/space/images/sunpp/right.gif" width="23" height="370"></td>

</tr>

</table>

<table width="100%" border="0" cellpadding="0" cellspacing="0">

<tr>

<td width="26" height="76" background="http://www.sunschina.com/space/images/sunpp/leftbg.gif">&nbsp;</td>

<td align="center" bgcolor="#FFFFFF"><table width="850" border="0" cellpadding="0" cellspacing="0" style="font-size: 11px; font-family: Tahoma, Arial">

<tr>

<td align="left"><img src="/img/linklogo.gif" width="88" height="31" align="top"/>&nbsp;&nbsp;<a href="/bbs/rule.php?tid=1">关于我们</a>&nbsp;&nbsp;|&nbsp;&nbsp;<a href="/bbs/rule.php?tid=2">免责声明</a><a href="thread-1524050-1-1.html"></a>&nbsp;&nbsp;|&nbsp;&nbsp;<a href="/bbs/rule.php?tid=3">隐私政策</a><a href="rule.php?tid=1524050"></a><a href="thread-1524050-1-1.html"></a>&nbsp;&nbsp;|&nbsp;&nbsp;<a href="/bbs/rule.php?tid=4">联系我们</a><a href="mailto: "></a>&nbsp;&nbsp;|&nbsp;&nbsp;<a href="http://www.sunschina.org" target="_blank">会服中心</a>

<br /></td>

<td align="right" valign="top" class="footerlink"><a href="#top"><img src="http://www.sunschina.com/space/images/sunpp/gototop.gif" border="0" /></a></td>

</tr>

<tr>

<td align="left" valign="bottom" style="font-size:11px; font-family:sans-serif;Arial, Helvetica">

Powered by <a href="http://x-space.discuz.net" target="_blank"><font color="#7186B0"><strong>X-Space</strong></font></a>

1.0 &copy; 2001-2006 <a href="http://www.comsenz.com" target="_blank">Comsenz Technology Ltd</a>

<br />

<font color="#0000FF">招商电话:+86.12345678900 客服热线:+86.12345678900 法律顾问:+86.12345678900</font></td>

<td align="right" valign="bottom" style="font-size:11px; font-family:sans-serif;Arial, Helvetica">

&copy;2002 - 2006 <b>日光海岸 <a href="http://www.sunschina.com">SunsChina.com</a></b> All Rights Reservsed <br /> <a target="_blank" href="http://www.miibeian.gov.cn"><font color="#333333">鄂ICP备05005214号</font></a>

<script language="javaScript" type="text/Javascript" src="http://js.d.s35.51.la/1566.js"></script>

<script language='JavaScript' src='http://v2.cnzz.com/stat.php?id=48085&amp;web_id=48085&amp;show=pic' type="text/javascript" charset='gb2312'></script>

<strong>Skin Designed by Danny</strong></td>

</tr>

</table>

</td>

<td width="23" height="76" background="http://www.sunschina.com/space/images/sunpp/rightbg.gif">&nbsp;</td>

</tr>

</table>

<table width="100%" border="0" cellpadding="0" cellspacing="0" background="http://www.sunschina.com/space/images/sunpp/footbg.gif">

<tr>

<td width="40" height="31"><img src="http://www.sunschina.com/space/images/sunpp/footleft.gif" width="40" height="31" /></td>

<td align="right" background="http://www.sunschina.com/space/images/sunpp/cpimgup.gif">&nbsp;

</td>

<td width="40" height="31"><img src="http://www.sunschina.com/space/images/sunpp/footright.gif" width="40" height="31" /></td>

</tr>

</table>

2、保存该文件,然后刷新X-Space首页,就可以看到修改后的首页

图片4

3、但是页面主体与左右两边的间距有些大了,造成了布局上的不美观。用记事本或编辑器打开“/supesite/CSS/main.css”,在第92行修改wrap的宽度为:“width: 850px; ”

4、然后保存该文件,刷新X-Space首页。至此,对X-Space首页的修改已经基本完成。

5、接下来是对“日志”、“资讯”、“相册”、“文件”等相关页面的风格统一化修改,修改方法与首页操作步骤相同。

总结

风格统一化修改其实很简单,要修改页面头部和左边的风格,只需要改动对应的header模板即可,而对应的右边和底部的风格,则在footer模板里修改。

 
 
 
免责声明:本文为网络用户发布,其观点仅代表作者个人观点,与本站无关,本站仅提供信息存储服务。文中陈述内容未经本站证实,其真实性、完整性、及时性本站不作任何保证或承诺,请读者仅作参考,并请自行核实相关内容。
2023年上半年GDP全球前十五强
 百态   2023-10-24
美众议院议长启动对拜登的弹劾调查
 百态   2023-09-13
上海、济南、武汉等多地出现不明坠落物
 探索   2023-09-06
印度或要将国名改为“巴拉特”
 百态   2023-09-06
男子为女友送行,买票不登机被捕
 百态   2023-08-20
手机地震预警功能怎么开?
 干货   2023-08-06
女子4年卖2套房花700多万做美容:不但没变美脸,面部还出现变形
 百态   2023-08-04
住户一楼被水淹 还冲来8头猪
 百态   2023-07-31
女子体内爬出大量瓜子状活虫
 百态   2023-07-25
地球连续35年收到神秘规律性信号,网友:不要回答!
 探索   2023-07-21
全球镓价格本周大涨27%
 探索   2023-07-09
钱都流向了那些不缺钱的人,苦都留给了能吃苦的人
 探索   2023-07-02
倩女手游刀客魅者强控制(强混乱强眩晕强睡眠)和对应控制抗性的关系
 百态   2020-08-20
美国5月9日最新疫情:美国确诊人数突破131万
 百态   2020-05-09
荷兰政府宣布将集体辞职
 干货   2020-04-30
倩女幽魂手游师徒任务情义春秋猜成语答案逍遥观:鹏程万里
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案神机营:射石饮羽
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案昆仑山:拔刀相助
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案天工阁:鬼斧神工
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案丝路古道:单枪匹马
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案镇郊荒野:与虎谋皮
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案镇郊荒野:李代桃僵
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案镇郊荒野:指鹿为马
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案金陵:小鸟依人
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案金陵:千金买邻
 干货   2019-11-12
 
推荐阅读
 
 
 
>>返回首頁<<
 
靜靜地坐在廢墟上,四周的荒凉一望無際,忽然覺得,淒涼也很美
© 2005- 王朝網路 版權所有