update demo to take $name pram