Re: Problem checking an existing browser cookie

2010-09-01 Thread Nik the Greek
On 31 Αύγ, 11:07, Nik the Greek wrote: > On 30 Αύγ, 20:50, MRAB wrote: > > > > > > > > > > > On 30/08/2010 18:16, Nik the Greek wrote: > > > > On 30 Αύγ, 19:41, MRAB  wrote: > > >> On 30/08/2010 04:33, Nik the Greek wrote: >

Re: Problem checking an existing browser cookie

2010-08-31 Thread Nik the Greek
On 30 Αύγ, 20:50, MRAB wrote: > On 30/08/2010 18:16, Nik the Greek wrote: > > > > > > > > > > > On 30 Αύγ, 19:41, MRAB  wrote: > >> On 30/08/2010 04:33, Nik the Greek wrote: > > >>> On 30 Αύγ, 06:12, MRAB    wrote: > > >>

Re: Problem checking an existing browser cookie

2010-08-31 Thread Nik the Greek
On 30 Αύγ, 20:48, Rami Chowdhury wrote: > On Mon, Aug 30, 2010 at 23:36, Nik the Greek > wrote: > > > > > > > > > > > # initialize cookie > > cookie = SimpleCookie() > > cookie.load( os.environ.get('HTTP_COOKIE', '

Re: Problem checking an existing browser cookie

2010-08-30 Thread Nik the Greek
On 30 Αύγ, 20:53, MRAB wrote: > > Why visitor.value is undefined? > > Because visitor is None. It's not seeing any cookie. WHY NOT?! THE COOKIE _DOES_EXIST !!! What am i missing here?! -- http://mail.python.org/mailman/listinfo/python-list

Re: Problem checking an existing browser cookie

2010-08-30 Thread Nik the Greek
On 30 Αύγ, 19:41, MRAB wrote: > On 30/08/2010 04:33, Nik the Greek wrote: > > > > > > > > > On 30 Αύγ, 06:12, MRAB  wrote: > > >> This part: > > >>       ( not mycookie or mycookie.value != 'nikos' ) > > >> is false but

Re: Problem checking an existing browser cookie

2010-08-30 Thread Nik the Greek
On 30 Αύγ, 19:21, Peter Otten <__pete...@web.de> wrote: > Nik the Greek wrote: > >> Perhpas its doenst get loaded like that? > > >> # initialize cookie > >> cookie = SimpleCookie() > >> cookie.load( os.environ.get('HTTP_COOKIE', ''

Re: Problem checking an existing browser cookie

2010-08-30 Thread Nik the Greek
On 30 Αύγ, 19:41, MRAB wrote: > On 30/08/2010 04:33, Nik the Greek wrote: > > > > > > > > > On 30 Αύγ, 06:12, MRAB  wrote: > > >> This part: > > >>       ( not mycookie or mycookie.value != 'nikos' ) > > >> is false but

Re: String substitution VS proper mysql escaping

2010-08-30 Thread Nik the Greek
On 30 Αύγ, 11:11, Gregory Ewing wrote: > Nik the Greek wrote: > > Yes i will i just asked to know if i were to substitute what might be > > the problem so to understand why i need the quoting. > > Because if you use % to build a query string, the result must > be synt

Re: Problem checking an existing browser cookie

2010-08-30 Thread Nik the Greek
On 30 Αύγ, 11:01, Nik the Greek wrote: > On 30 Αύγ, 06:12, MRAB wrote: > > > > > > > > > > > On 30/08/2010 03:55, Nik the Greek wrote: > > > > On 30 Αύγ, 05:43, MRAB  wrote: > > >> On 30/08/2010 03:07, Nik the Greek wrote: > > &

Re: Problem checking an existing browser cookie

2010-08-30 Thread Nik the Greek
On 30 Αύγ, 06:12, MRAB wrote: > On 30/08/2010 03:55, Nik the Greek wrote: > > > > > > > > > > > On 30 Αύγ, 05:43, MRAB  wrote: > >> On 30/08/2010 03:07, Nik the Greek wrote: > > >>> On 30 Αύγ, 04:51, MRAB    wrote: > >>

Re: Problem checking an existing browser cookie

2010-08-29 Thread Nik the Greek
On 30 Αύγ, 06:12, MRAB wrote: > This part: > >      ( not mycookie or mycookie.value != 'nikos' ) > > is false but this part: > >      re.search( r'(msn|yandex|13448|spider|crawl)', host ) is None > > is true because host doesn't contain any of those substrings. So, the if code does executed bec

Re: String substitution VS proper mysql escaping

2010-08-29 Thread Nik the Greek
On 30 Αύγ, 05:48, MRAB wrote: > On 30/08/2010 03:33, Nik the Greek wrote: > > > > > > > > > On 30 Αύγ, 05:04, MRAB  wrote: > > > when iam trying to pass a tuple to the execute methos should i pass it > > like this? > > > cursor.execute(

Re: Problem checking an existing browser cookie

2010-08-29 Thread Nik the Greek
On 30 Αύγ, 05:43, MRAB wrote: > On 30/08/2010 03:07, Nik the Greek wrote: > > > > > > > > > > > On 30 Αύγ, 04:51, MRAB  wrote: > >> On 30/08/2010 02:14, Νίκος wrote: > > >>> On 29 Αύγ, 21:44, MRAB    wrote: > >>>> On

Re: String substitution VS proper mysql escaping

2010-08-29 Thread Nik the Greek
On 30 Αύγ, 05:04, MRAB wrote: when iam trying to pass a tuple to the execute methos should i pass it like this? cursor.execute(''' SELECT hits FROM counters WHERE page = %s and date = %s and host = %s ''' % (page, date, host) ) or like tuple = (page, host, date) cursor.execute(''' SELECT hit

Re: Problem checking an existing browser cookie

2010-08-29 Thread Nik the Greek
On 30 Αύγ, 04:51, MRAB wrote: > On 30/08/2010 02:14, Νίκος wrote: > > > > > > > > > > > On 29 Αύγ, 21:44, MRAB  wrote: > >> On 29/08/2010 06:34, Νίκος wrote: > > >>> On 28 Αύγ, 23:15, MRAB    wrote: > On 28/08/2010 20:37, Íßêïò wrote: > > > On 22 Áýã, 10:27, Íßêïò      wrote: > >> On