left4dead2求生之路2服务器motd不显示图片的解决办法
由于在网上几乎找不到求生之路2 Linux平台搭建的专用服务器今日消息motd不显示图片等问题的解决办法,故记录此次问题的解决方法。(left 4 dead 2 Dedicated server built on linux platform motd can’t display images)
方法来源https://forum.myarena.ru/index.php?/topic/44435-motd-okno/
修改left4dead2/cfg/server.cfg文件,另起一行添加
sm_cvar motd_enabled 1
motd_enabled "1"
我是使用了静态网页放置显示图片的网址,网页代码如下
<html> <head><head> <style type="text/css"><style type="text/css"> body {{ margin-left: 0px;-left: 0px; margin-top: 0px;-top: 0px; margin-right: 0px;-right: 0px; margin-bottom: 0px;-bottom: 0px; background-color: #000000;-color: #000000; }} </style></style> </head></head> <body><body> <img src="motd.jpg" width="100%" border="0" align="center"> </body></body> </html></html>
将网页命名为index.html文件并放在网站可被访问的目录下,并将motd.jpg文件放在同一目录下。如下图
然后将服务器的motd.txt文件内容改成静态网页的网址,我这里是http://songzx.com/me/,注意,可能需要http协议。
更改好后重启服务器。
至于其他的方法,比如直接在motd.txt内容中嵌入html代码,或将图片换为网页地址,可以自行尝试是否可行。
文章留言