You are here: Re: Reading a cookie « PHP Programming Language « IT news, forums, messages
Re: Reading a cookie

Posted by Jerim79 on 02/07/07 18:00

On Feb 7, 11:59 am, Rik <luiheidsgoe...@hotmail.com> wrote:
> Jerim79 <m...@hotmail.com> wrote:
> >> > Okay, so we are going with cookies. The problem I have is that I don't
> >> >> > know how to make PHP just read acookie.
>
> >> >> It's in the $_COOKIE array.
>
> >> > I tried that and it doesn't seem to work. For instance:
>
> >> Do a var_dump($_COOKIE);
> >> If nothing is set, the browser probably did not send acookie, and you'll
> >> have to check wether thecookieyou're expecting is set correctly.
>
> > Right, we don't want to set acookie. EVER. We just want to READ a
> >cookiethat we create manually, ourselves.
>
> And thecookieHAS TO BE SET, SOMETIMES, BY AN ARIBTRARY PROGRAM, SCRIPT
> OR PERSON. If nocookieis set, or you've set it with the wrong
> parameters, PHP will never receive it.
>
> You cannot just expect something exists by just checking wether it exists.
>
> > I know in javascript you can create acookiemanually and have
> > javascript read it. We want to do that in PHP.
>
> No, you just told me you did not want to create it. Get your plan straight.
>
> --
> Rik Wasmus

When you say "set the cookie" I take that to mean setcookie(). I don't
want setcookie(). I want to create the cookie manually. So I can
create the cookie called "printer" manually and use
$_COOKIE['printer'] to read it?

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация