Allow having prefix specific layouts.

Refs #3907
Merge pull request #3935 from ADmad/3.0-prefix-template-path

Allow having prefix specific layouts.