WP-PostViews 1.11使用方法

  

General Usage

Open wp-content/themes//index.php

You may place it in single.php, post.php or page.php also.

Find:

Add Anywhere Below It:

The first value you pass in is the text for views.

Default: the_views('Views');

View Stats (Outside WP Loop)

To Display Most Viewed Post

Use:

The first value you pass in is what you want to get, 'post', 'page' or 'both'.

The second value you pass in is the maximum number of post you want to get.

Default: get_most_viewed('both', 10);

To Display Most Viewed Post For A Category

Use:

The first value you pass in is the category id.

The second value you pass in is what you want to get, 'post', 'page' or 'both'.

The third value you pass in is the maximum number of post you want to get.

Default: get_most_viewed_category(1, 'both', 10);


  •   正在提交中,请稍候...
      评论提交成功
    回复 的评论,点击取消回复