Sample code for 30+ languages & platforms
Tcl

Example: Http.GetRequestHeader method

Demonstrates the GetRequestHeader method.

Chilkat Tcl Downloads

Tcl

load ./chilkat.dll

set success 0

set http [new_CkHttp]

set hdr1 "X-CSRF-Token"
set hdr2 "X-Example"

CkHttp_SetRequestHeader $http $hdr1 "Fetch"
CkHttp_SetRequestHeader $http $hdr2 "123ABC"

puts "$hdr1: [CkHttp_getRequestHeader $http $hdr1]"
puts "$hdr2: [CkHttp_getRequestHeader $http $hdr2]"

# Output:

# X-CSRF-Token: Fetch
# X-Example: 123ABC

delete_CkHttp $http