Added basic code from SimpleTempelate