adding type for all header status code
adding CURLINFO attribute to get header size
Made some refactoring