correct snippets for php