Programming Theory
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Codewalkers ForumsOther TechnologiesProgramming Theory

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Codewalkers Forums Sponsor:
  #1  
Old June 4th, 2005, 12:52 AM
mbriggs5 mbriggs5 is offline
Codewalkers Newbie (0 - 499 posts)
 
Join Date: Apr 2007
Location: Peachtree City, Ga
Posts: 8 mbriggs5 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
what is the best technique

when creating and parsing forms. I have looked at quite a few books with different authors and each of them have a different approach to getting something done. So As i am learning this stuff it has become a little frustrating because each person has a different style.

So maybe this question is for someone with some expierance.


A form goes through the same couple of steps every time.

one way to do it s to write a form at the first step as simple html and when you submit it could be held in hidden fields and sent to an output.php then to a confirm.php.

you can also make the form start out as a form.php then parse directly to a "this data was inserted into the database" page.

I guess my question is if I am going to have a login page that goes into an admistration page and then customer service people will have the ability to add customers , delete customers or edit customers should i display the form first through a php page to a php page or go html - output.php then finally to a confirm.php?

I guess these are preferences in the way you can strategize on how to run through your basic forms . Anyway, its an interesting discussion and if anyone that can understand what the heck i am talking about above could maybe shed some direction form would be appreciated.

Reply With Quote
  #2  
Old June 5th, 2005, 10:54 PM
lig's Avatar
lig lig is offline
"Forum Nazi"
Codewalkers Demi-God (4500 - 4999 posts)
 
Join Date: Apr 2007
Location: Jacksonville, Fl
Posts: 4,729 lig User rank is Private First Class (20 - 50 Reputation Level)lig User rank is Private First Class (20 - 50 Reputation Level) 
Time spent in forums: 4 Days 1 h 32 m 7 sec
Reputation Power: 6
RE: what is the best technique

This is to me a matter of personal style and the requirements of security needed. Generally speaking I do most of my form handling on the same page as the form (unless I am using templates). I like having everything in one place (tend not to like to include things)- though that goes against the OOP model.

The only time I usually deviate from this is when I need a higher layer of security. This allows me tighter control of access to my db and a little more flexibility.

Reply With Quote
  #3  
Old June 6th, 2005, 01:23 AM
phu phu is offline
Codewalkers Newbie (0 - 499 posts)
 
Join Date: Apr 2007
Posts: 8 phu User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
RE: what is the best technique

After working on a very large project which has taken better than a year, my preferred method is to have pages refer to themselves, keep the formatting/database connection/GUI/session calls in a header file, and include function repositories for page-specific functions.

I tend to have a form call its own page, and parse the get/post variables whenever the page is called to determine what it should be doing.

Reply With Quote
Reply

Viewing: Codewalkers ForumsOther TechnologiesProgramming Theory > what is the best technique


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway
Stay green...Green IT