The death toll from a gas pipeline explosion in a Bangladeshi mosque has risen to 28 on Wednesday, a fire service official said.