Encode body content.