load user-required files from their own directory

These two commits are fixes for two issues I encountered trying to set up the snippet generation for a php project.