Typecho后台设置统计代码
以默认主题为例,在functions.php中找到themeConfig函数,在里面插入以下代码:
$analytics = new Typecho_Widget_Helper_Form_Element_Textarea('analytics', NULL, NULL, _t('统计代码'), _t('在这里添加统计代码'));
$form->addInput($analytics);然后在footer.php中,插入
<?php $this->options->analytics(); ?> 