WordPressLeaf主题设置:如何让每个访客都拥有头像?

导语:WordPress的头像对于国内的用户来说都是一个摆设,因为国内的访客一般都无法从头像网站上下载自己的头像,这就导致很多的WordPress网站的访客头像是一个无法打开的标志,但如果你是使用WordPressLeaf主题就完全不用担心这个问题。

WordPress头像缓存

WordPressLeaf主题考虑到国内访客的实际情况,为了达到美化页面和加快网页加载速度的目的,在主题内使用了头像缓存的功能,可以让网站从国外头像服务先下载头像到自己的网站,然后再展示给访客。头像缓存的有效期为7天。

对于那种访客没有设置头像和由于网络原因无法访问到头像的情况,WordPressLeaf主题会使用自己的头像库,从100张头像中随机出一张头像作为访客的头像写入缓存目录。随机头像缓存有效期同样为7天。

如何开启头像缓存

如果你使用WordPressLeaf主题,开启头像缓存很简单。进入WordPressLeaf高级设置,你会看到以下的设置项:

头像缓存

打勾表示开启。注意:请先在网站根目录下建立名为“avatar”的文件夹,例如“www.wordpressleaf.com/avatar/”。重要:在某些老的站点,更换Leaf主题开启头像缓存时,由于需要缓存的头像太多,可能会导致服务器卡死。

开启头像缓存。目前已开启。

正如选项所描述的,你先要在网站的跟目录下建立一个叫做“avatar”的目录,具有读写权限。目录建立后,点击“开启头像缓存”就可以了,这时候状态提示就会从“目前未开启”变为“目前已开启”。

你可以参照下图进行设置:

WordPressLeaf主题设置:如何让每个访客都拥有头像?
头像缓存设置

最终效果就是每个访客都有了头像,如下图:

WordPressLeaf主题设置:如何让每个访客都拥有头像?
访客头像

结束

头像设置是不是很简单,你学会了吗?如果你还需要进行其他方面的设置,可以看看WordPressLeaf主题安装设置步骤,或者点击WordPress主题来查看其他的设置技巧。


Warning: copy(): SSL operation failed with code 1. OpenSSL Error messages: error:14090086:SSL routines:ssl3_get_server_certificate:certificate verify failed in /opt/lampp/htdocs/wordpresssummer/wp-content/themes/summerleaf/inc/summer_setting.php on line 546

Warning: copy(): Failed to enable crypto in /opt/lampp/htdocs/wordpresssummer/wp-content/themes/summerleaf/inc/summer_setting.php on line 546

Warning: copy(https://www.wordpressleaf.com/wp-content/themes/summerleaf/images/tx/64.png): failed to open stream: operation failed in /opt/lampp/htdocs/wordpresssummer/wp-content/themes/summerleaf/inc/summer_setting.php on line 546

目前在“WordPressLeaf主题设置:如何让每个访客都拥有头像?”上有4条评论


  1. Warning: copy(): SSL operation failed with code 1. OpenSSL Error messages: error:14090086:SSL routines:ssl3_get_server_certificate:certificate verify failed in /opt/lampp/htdocs/wordpresssummer/wp-content/themes/summerleaf/inc/summer_setting.php on line 546

    Warning: copy(): Failed to enable crypto in /opt/lampp/htdocs/wordpresssummer/wp-content/themes/summerleaf/inc/summer_setting.php on line 546

    Warning: copy(https://www.wordpressleaf.com/wp-content/themes/summerleaf/images/tx/47.png): failed to open stream: operation failed in /opt/lampp/htdocs/wordpresssummer/wp-content/themes/summerleaf/inc/summer_setting.php on line 546
    米粒博客说道:

    很浪费空间的!


    1. Warning: copy(): SSL operation failed with code 1. OpenSSL Error messages: error:14090086:SSL routines:ssl3_get_server_certificate:certificate verify failed in /opt/lampp/htdocs/wordpresssummer/wp-content/themes/summerleaf/inc/summer_setting.php on line 546

      Warning: copy(): Failed to enable crypto in /opt/lampp/htdocs/wordpresssummer/wp-content/themes/summerleaf/inc/summer_setting.php on line 546

      Warning: copy(https://www.wordpressleaf.com/wp-content/themes/summerleaf/images/tx/15.png): failed to open stream: operation failed in /opt/lampp/htdocs/wordpresssummer/wp-content/themes/summerleaf/inc/summer_setting.php on line 546
      编辑 杨说道:

      头像其实很小的。萝卜白菜,各有所爱。呵呵


  2. Warning: copy(): SSL operation failed with code 1. OpenSSL Error messages: error:14090086:SSL routines:ssl3_get_server_certificate:certificate verify failed in /opt/lampp/htdocs/wordpresssummer/wp-content/themes/summerleaf/inc/summer_setting.php on line 546

    Warning: copy(): Failed to enable crypto in /opt/lampp/htdocs/wordpresssummer/wp-content/themes/summerleaf/inc/summer_setting.php on line 546

    Warning: copy(https://www.wordpressleaf.com/wp-content/themes/summerleaf/images/tx/75.png): failed to open stream: operation failed in /opt/lampp/htdocs/wordpresssummer/wp-content/themes/summerleaf/inc/summer_setting.php on line 546
    天行者说道:

    挺好的


    1. Warning: copy(): SSL operation failed with code 1. OpenSSL Error messages: error:14090086:SSL routines:ssl3_get_server_certificate:certificate verify failed in /opt/lampp/htdocs/wordpresssummer/wp-content/themes/summerleaf/inc/summer_setting.php on line 546

      Warning: copy(): Failed to enable crypto in /opt/lampp/htdocs/wordpresssummer/wp-content/themes/summerleaf/inc/summer_setting.php on line 546

      Warning: copy(https://www.wordpressleaf.com/wp-content/themes/summerleaf/images/tx/58.png): failed to open stream: operation failed in /opt/lampp/htdocs/wordpresssummer/wp-content/themes/summerleaf/inc/summer_setting.php on line 546
      编辑 杨说道:

      常来看看。

发表评论

邮箱地址不会被公开。 必填项已用*标注