Reply to Re: PHP - Best (or better) practice for Forms?

Your name:

Reply:


Posted by Oli Filth on 09/06/05 02:47

David said the following on 05/09/2005 23:58:
> I have a web app that is forms intensive. These forms have a number
> of dropdown lists, check box, etc., each which requires additional
> processing, db calls, etc. On an item changed, I post back the form
> and set a hidden field to tell PHP what changed so it knows what to
> process.

This relies on Javascript being enabled, and is a waste of bandwidth
(you need to send a load of extra HTML, and the form submission requires
a load of extra fields).

Why do you need to know exactly what was changed? Why not just update
everything when you've received the form submission?

If you're worried about speed, it will make virtually zero speed
difference whether you update one field in a table row, or the whole row.

If you need to identify changes in values to trigger specific actions,
then either extract the original values from the DB and do a comparison
server-side, or store the original values in $_SESSION.


--
Oli

[Back to original 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

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