Drupal 7: Do not count visits of bots or spammers

If you use the statistics module (in core in Drupal 7) to show how many times an article was read, there are two problems with that number

  1. also bots and spammers are count
  2. if you reload the page (e.g. with F5) the number is incremented


Browse to 


and check

Disable user registration in Drupal 7

If you have a simple side, where you don't want everybody to be able to register, especially not bots, you can only grant the administrator the rights to create new users. 

In Drupal 7, browse to


and set

Who can register accounts?


Drupal - How to show content with the same tags below a menu tab

If you e.g. want to show all blog entries with the tag "bash" when clicking on the menu tab "bash", here is what you have to do.

Install following two modules:



and enable views, views ui and ctools.

go to
  structure > views > add new view

  View name: bash_view
  Show Content of type all tagged with YOUR-TAG sorted by Newest first  

Drupal - include code highlighting tools (google prettify) with CKEditor

This post explaines how to get highlighted code in Drupal 7 like:

for i = 1:3
   j = i;

For me the combination of CKEditor and the code highlighting tool Geshi did not work.

Hence I tried the combination of the module [[https://www.drupal.org/project/prettify | google code prettify]] (which is used by stackoverflow.com) and CKEditor.


CKEditor must be installed. See other post for that.

Getting it to run