Hi
I have always felt for reasons for cleanliness and clarity, it is
better to have the validation and insert / update statements in a
seperate file rather than have it in the same script.
Case 1
--
//file:form.php
if $_POST
then validate
Insert or update on success
else
if
Hello Vinayakam,
Tuesday, March 8, 2005, 4:11:43 AM, you wrote:
V However in the second case, in case of an error, displaying the
V data becomes an issue.
V Any recommended ways for server side validation
I usually do the updates in the same file unless there are a lot of
different things
The way I do it is to have display, edit, validation and save all in
the same file. I have an op variable that tracks whether the
operation is an edit or reedit (reuse submitted data) because of
validation failure. Another variable would track if it's a new entry
(blank fields) or editing an
3 matches
Mail list logo