add site handler middleware