He encamped before Joppa, but the people of the city closed its gates, for Apollonius had a garrison in Joppa.