PHP Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 



Go Back   Dev Articles Community ForumsProgrammingPHP Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
  #1  
Old April 14th, 2002, 12:36 PM
sannu sannu is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Apr 2002
Posts: 1 sannu User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Questionnaire and php

On this url http://www.hot.ee/sannu/kysimused.html
I have questionnaire (sorry about pop-up, it's free host). Now if someone fills in he questionnaire, i have to check if he/ she filled in all form fields.
If button 'Saada' (submit) is pressed, script should show if some field isn't filled in. Now there is choice, go back and fill in unfilled forms or send as it is.
Data will be written into text file, delimiter is '|', because then it's easy to import this data into excel table.
But as you can see, it isn't very easy. The solution is array, but how excactly, don't know.
My description isn't very well, but hope you understand the situation.
Thanx

Last edited by sannu : April 15th, 2002 at 06:55 AM.

Reply With Quote
  #2  
Old April 14th, 2002, 06:47 PM
Ben Rowe
Guest
Dev Articles Newbie (0 - 499 posts)
 
Posts: n/a  
Time spent in forums:
Reputation Power:
hmmm, i tried the url, but it came up as page cannot be displayed?? is it the right url???

Reply With Quote
  #3  
Old April 14th, 2002, 08:55 PM
MTran MTran is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Apr 2002
Posts: 9 MTran User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
First off, dont reply on the user clicking a button to submit the form. they could press enter in the text fields as well. for the fields, im assuming your using php so use the global accessi modifier like this

global $HTTP_POST_VARS;

to get the post values. so if u had <input type="text" name="blah"> it would be

if($HTTP_POST_VARS["blah"] == "")
echo "Empty blah field";

then to combine them with a delimiter just do it manually:

$final = $HTTP_POST_VARS["blah"] . "|" . $HTTP_POST_VARS["blee"];

etc...

Reply With Quote
  #4  
Old April 14th, 2002, 09:22 PM
rathaur rathaur is offline
Contributing User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Apr 2002
Location: Malaysia
Posts: 82 rathaur User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 42 m 57 sec
Reputation Power: 17
There are some simple Javascript available to check our forms. i will pass u the codes, ,later but you also can find it from sites like www. javascripts.com.
using javascript for form checking have some advatanges, thats it reduce the load on server alone. Its faster, and popup windows will display the error messages.
__________________
Rathaur
======================
Knowledge is Power

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsProgrammingPHP Development > Questionnaire and php


Developer Shed Advertisers and Affiliates


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 | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.

© 2003-2018 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap