如何为moodle block添加icon?

来源:互联网 发布:linux ftp服务器配置 编辑:程序博客网 时间:2024/05/16 14:57


By default, 你开发一个blockicon是没有的(如下图)


如何可以像上面的第一个block那样有一个icon? 使用firefox能查看到下列结果

 

 

可以见到原来blockheadericon是通过<your theme folder>/styles.php设置的css来设置background url属性的。再细看该styles.php(我们使用的themecollege blue theme),设置background url属性在college_blue.css file。因此,针对你的blockcollege_blue.css里添加对应的css codes

 

假设你的blockbu_lib_tool,那么你应该添加css code

div.block_bu_lib_tool div.header {

background:url("images/block_bu_lib_tool.jpg") no-repeat scroll left center #FFFFFF;

}

 

然后把block_bu_lib_tool.jpg放到<your theme>/images目录下!

 

 

 

 

原创粉丝点击