added get param method $p, changed route handling method