I am starting my first PHP project at my company. We are running Zend Server on an IBM i (AS/400).
I want to create a form-driven webpage that is for internal use only in our company. I want to create a form where the user will enter an item number in a text box for inquiry. When the user submits the form, it will display item information from a DB in more textboxes. The user will have the option of making changes in the textboxes and when they submit the form again, the changes will be updated back to the DB.
What would be a good approach? Should I have the HTML form in one PHP file and have the PHP code for inquiry/update in another file(s) and use requires()? If I take this approach, I would probably need to do action="<? php echo $_SERVER['PHP_SELF']; ?." on the form. Is that correct?
Or, is there a way to do action="inquire.php" and/or action="update.php" on the "main" form? In any case, the user would need the abilty "go back" to the "original screen" to inquire on a different item number at any time.
I hope this description makes sense. I'm just looking for the best approach without getting involved with MVC at this point. Any recommendations? Thanks.