Some more debug information, count time in mysqli statements and make select page work.