去除ecshop中的开源标签

查看ecshop的页面源代码,我们会发现有这样一句话:

<meta content=”ECSHOP v2.7.2″ />

这个是ecshop的版本信息,为了站点安全,应该将其去除。

打开includes/cls_template.php 约为1087行

$source = preg_replace(‘/<head>/i’, “<head> <meta name=\”Generator\” content=\”” . APPNAME .’ ‘ . VERSION . “\” />”,  $source);

可以将其去除和修改。

其中APPNAME和VERSION在includes/cls_ecshop.php中:

define(‘APPNAME’, ‘ECSHOP’);

define(‘VERSION’, ‘v2.7.2′);

Leave a comment

Your comment

*
To prove you're a person (not a spam script), type the security word shown in the picture. Click on the picture to hear an audio file of the word.
Click to hear an audio file of the anti-spam word