{"id":584,"date":"2006-04-13T00:13:53","date_gmt":"2006-04-12T22:13:53","guid":{"rendered":"http:\/\/www.rare-it.com\/blog\/index.php\/2006\/04\/13\/count-myself-out\/"},"modified":"2013-07-24T19:04:17","modified_gmt":"2013-07-24T17:04:17","slug":"count-myself-out","status":"publish","type":"post","link":"https:\/\/www.switchbl8.nl\/blog\/2006\/04\/count-myself-out\/","title":{"rendered":"Count myself out"},"content":{"rendered":"<p>When switching to WordPress, I changed the URL of my counter as well, and included the scripting part in the footer of the page. It creates this icon <img loading=\"lazy\" decoding=\"async\" width=\"11\" height=\"11\" alt=\"nedstat.gif\" id=\"image585\" src=\"http:\/\/www.switchbl8.nl\/blog\/wp-content\/uploads\/2006\/04\/nedstat.gif\" \/>, and when displayed, you&#8217;re counted. But when experimenting with themes or other settings, I view my own pages a lot. So yesterday was a day with a lot of hits. Today I added some code to the template, to show the icon only to people not logged in, which basically counts me out.<\/p>\n<p>The code:<\/p>\n<pre class=\"brush: php; title: ; notranslate\" title=\"\">&lt;?php if (!current_user_can('edit_posts')) { ?&gt;<\/pre>\n<p>and right behind the scripting part:<\/p>\n<pre class=\"brush: php; title: ; notranslate\" title=\"\">&lt;?php } ?&gt;<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>When switching to WordPress, I changed the URL of my counter as well, and included the scripting part in the footer of the page. It creates this icon , and when displayed, you&#8217;re counted. But when experimenting with themes or other settings, I view my own pages a lot. So yesterday was a day with <a href='https:\/\/www.switchbl8.nl\/blog\/2006\/04\/count-myself-out\/' class='excerpt-more'>[&#8230;]<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[38],"tags":[],"class_list":["post-584","post","type-post","status-publish","format-standard","hentry","category-blogging","category-38-id","post-seq-1","post-parity-odd","meta-position-corners","fix"],"_links":{"self":[{"href":"https:\/\/www.switchbl8.nl\/blog\/wp-json\/wp\/v2\/posts\/584","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.switchbl8.nl\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.switchbl8.nl\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.switchbl8.nl\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.switchbl8.nl\/blog\/wp-json\/wp\/v2\/comments?post=584"}],"version-history":[{"count":3,"href":"https:\/\/www.switchbl8.nl\/blog\/wp-json\/wp\/v2\/posts\/584\/revisions"}],"predecessor-version":[{"id":1593,"href":"https:\/\/www.switchbl8.nl\/blog\/wp-json\/wp\/v2\/posts\/584\/revisions\/1593"}],"wp:attachment":[{"href":"https:\/\/www.switchbl8.nl\/blog\/wp-json\/wp\/v2\/media?parent=584"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.switchbl8.nl\/blog\/wp-json\/wp\/v2\/categories?post=584"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.switchbl8.nl\/blog\/wp-json\/wp\/v2\/tags?post=584"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}