httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sanoadi <aditya.si...@xoserve.com>
Subject cookie to apache 2.2
Date Tue, 14 Sep 2010 14:42:41 GMT

Hi I am sending the cookie back to web server (appache 2.2) ; it is not
getting recognized. 

 Cookie is prepared in the below method, where variable cookie used contains
all the cookies received in the header from the response. 

   protected String prepareCookie() 
    { 
        String cookieValue = ""; 
        for(int z=0; z<cookie.size(); z++) 
        { 
            KeyValueInfo keyValueInfo = (KeyValueInfo)cookie.get(z); 
            String key = (String)keyValueInfo.getKey(); 
            String value = (String)keyValueInfo.getValue(); 
            if(key.equalsIgnoreCase("Set-Cookie")) 
            { 
                if(cookieValue.equals("")) 
                { 
                    cookieValue = cookieValue + value; 
                } 
                else 
                { 
                    cookieValue = cookieValue + "," + value; 
                } 
            } 
        }         
        return cookieValue; 
    } 

Now when I send this cookie it is not recognized , however if I replace
comma with semi-colon while adding cookies in the above method it works
fine. Let me knoe if there is any to do solve this. I chant change the code
of the client to prepare cookie to replace comma to semi colon. 

Regards, 
Adi 

-- 
View this message in context: http://old.nabble.com/cookie-to-apache-2.2-tp29709332p29709332.html
Sent from the Apache HTTP Server - Dev mailing list archive at Nabble.com.


Mime
View raw message