show views of your blog

2014-02-14 10:43:27

Often we want to know how many people read our articles,and it’s pleasure for us to see our articles were read by many times.

In fact,it’s not difficult as you think. Now, let’s start:

First, we should download a plugin ‘WP-PostViews‘,this plugin enables you to display how many times a post/page had been viewed.Then you should do as follows:

1.Open wp-content/plugins Folder;

2.Put: Folder: wp-postviews;

3.Activate WP-PostViews Plugin;

4.Go to WP-Admin -> Settings -> PostViews to configure the plugin.

Next you should add code in your blog:

1.Open wp-content/themes//index.php;

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

3.Find: posts()) : thepost(); ?>;

4.Add Anywhere Below It (The Place You Want The Views To Show): exists(‘theviews’)) {

the_views(); } ?>.

Tt’s finished now,it’s sample,right?

侧边栏跟随滚动

当一篇文章比较长时,为了获得跟好的用户体验,我们就会考虑,如何为自己的博客设置一个跟随文章滚动的侧边栏,这样还可以使需要推崇的内容得到跟多关注,尤其对于广告展示来说,不失为增加广告展示盒点击量的一个好方法。 首先,我们需要引入jQuery,可以下载最新的jQuery或是直接引用google的API. 本地引入<script type="text/javascript" src="jQuery路径"></script> 调用google <script type="text/javascript"<br></br> src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"><

jQuery Mobile一个文件中创建多个页面

在 jQuery Mobile,您可以在单一 HTML 文件中创建多个页面。只需通过唯一的 id 来分隔每张页面,并使用 href 属性来连接彼此即可: welcome to my blog Welcome! This is page one turn to page two footer welcome to my blog Goodbye! This is page two turn to page one footer