You are here: Re: why use $_POST when you have $_SESSION? « PHP Programming Language « IT news, forums, messages
Re: why use $_POST when you have $_SESSION?

Posted by Rik on 01/28/07 18:47

Tony Marston <tony@NOSPAM.demon.co.uk> wrote:

>
> "Jerry Stuckle" <jstucklex@attglobal.net> wrote in message
> news:wfKdnTa_dtSiNSHYnZ2dnUVZ_vXinZ2d@comcast.com...
>> Tony Marston wrote:
>>> "Paul Lautman" <paul.lautman@btinternet.com> wrote in message
>>> news:51v4v1F1k55ftU1@mid.individual.net...
>>>> Tony Marston wrote:
>>>>
>>>>> You will always use $_POST when sending
>>>>> data from the client to the server,
>>>> Except when you use $_GET or $_REQUEST
>>>
>>> Wrong. $_GET is used to request data FROM the server, while $_POST i=
s
>>> used to send data TO the server.
>>>
>>
>> No, Tony. $_GET is used to fetch information from the query string. =
=

>> This
>> can be from several sources - including <form action=3Dget...>. But =
$_GET
>> is always used on the server, and the data always comes from the =

>> browser.
>
> I disagree. The GET method is used to fetch data from the server and =

> send it
> to the client. The POST method is use to send data from the client to =
the
> server. The GET method is bookmark-able, whereas the POST method is no=
t.
> This is the correct way as it is not good practice to bookmark a URL =

> which
> updates the server.

In both cases data is sent to the server. However, GET should only be us=
ed =

to retrieve (specific) data, POST can be used to alter(add/delete/edit) =
=

data. That's what was meant I'd say.
-- =

Rik Wasmus

 

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

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