Cookie issue(cant fix it with anyhting)
Denis McMahon
denismfmcmahon at gmail.com
Sun Oct 27 14:01:11 EDT 2013
On Sat, 26 Oct 2013 15:29:52 +0300, Nick the Gr33k wrote:
> Hello i having the following code to try and retrieve the visitor's
> saved cookie form the browser.
>
> [CODE]
> # initialize cookie and retrieve cookie from clients browser try:
> cookie = cookies.SimpleCookie( os.environ['HTTP_COOKIE'] )
> cookieID = cookie['name'].value
> except:
> cookieID = 'visitor'
> [/CODE]
>
> It works as expected except form the fact from when the visitor enters
> my webpage(superhost.gr) by clicking a backlink of another webpage.
>
> Then even if the cookie exists in his browser for some reason the try
> fails and except take actions.
>
> Can somebody explain why this is happening?
>
> You can see this action yourself by hitting:
>
> 1. superhost.gr as a direct hit 2. by clicking superhost.gr's backlink
> from ypsilandio.gr/mythosweb.gr
>
> You will see than in 2nd occasion another ebtry will appear in the
> database here:
>
> http://superhost.gr/?show=log&page=index.html
OK
I tried it. The counter in the database is incrementing (I think it's the
counter). There's only one entry in the table for my system.
I used the backlinks on each of the two pages above - the backlink on
mythosweb.gr I used twice.
So, whatever behaviour you're seeing is not what I'm seeing.
--
Denis McMahon, denismfmcmahon at gmail.com
More information about the Python-list
mailing list