validating menu resource extension. Accepting only pdf