Adding edit post functionality and template