how do I set a custom header in a curl config file

前端 未结 2 1039
心在旅途
心在旅途 2021-01-13 16:16

How do I add the option for setting a custom header in a curl config file? Neither of the following lines did work:

Header = \'x-abc: xyz\'
header = \'x-abc:         


        
2条回答
  •  一向
    一向 (楼主)
    2021-01-13 17:16

    Regarding your snippet with the code: you just needed to use double quotes " instead of single quotes '.

    With this change both statements work fine.

    Header = "x-abc: xyz"
    header = "x-abcd: xyz"
    

提交回复
热议问题