I'm trying to find if there is a bug in my code in regards to the use I do with WWC. It is about the header garbage we receive sometimes. This happens more frequently since a while and I don't know if it is because of the increase of traffic or else. But, I would like to verify something.
The only place we deal with headers is when we have to send a cookie. During the process, if a cookie has to be sent, we include them in an array. Then, at the end, when returning everything to WWC, to verify if we have something in the array. If yes, we execute the following code:
IF LEN(gaCookie[1,1])>0
LOCAL loHeader,lnCompteur
loHeader=CREATEOBJECT('wwHTTPHeader')
loHeader.DefaultHeader()
FOR lnCompteur=1 TO ALEN(gaCookie,1)
loHeader.AddCookie(gaCookie[lnCompteur,1],gaCookie[lnCompteur,2],'/')
NEXT
Response.ContentTypeHeader(loHeader)
ENDIF
So, basically, when we have to send a cookie, we create loHeader as an object. We call the default header and we use the AddCookie() method to add all required cookie in the header.
Anyone see something wrong with this code?