473,395 Members | 1,574 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

php script on personality test

hello is there anyone who could help me with scripting the personality test im making..it does not calculate the numbers that should be grouped..im not sure why..pls help me..
Attached Files
File Type: zip personality.zip (5.4 KB, 392 views)
Aug 5 '10 #1
4 3657
johny10151981
1,059 1GB
you have syntax error, in your php page
check line 120

if ($q1==eia)

what is eia you have error like this.

Besides there is another problem with exception handling. what if user skip any answer choose none of the answer? it will create "Undefined Index" error where you receiving POST value.
Aug 5 '10 #2
line 120 means it's the check value of the radio button..
then if it's the one being chose, it should add to the value of extrovert but if "eib" is chosen, it should add to the value of introvert..but it's not calculating..thanks man...
Aug 5 '10 #3
johny10151981
1,059 1GB
line 120 means it's the check value of the radio button..

This is a bug in your program. I think your php.ini settings file "display_errors" is off. set display_errors=on restart your apache server. And then try to understand what i have told you.
there is no such constant called eib(at least my php version, the latest one, dont support it)
Aug 5 '10 #4
TheServant
1,168 Expert 1GB
You can compare variables to variables, or variables to strings. You are not doing either in that line. If eib is a string that is chosen it should be:
Expand|Select|Wrap|Line Numbers
  1. if ($q1=="eia")
Aug 5 '10 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: John Ramsden | last post by:
I have a perl logging module that sends log messages, via post variables, to a simple PHP web app whose purpose is to write them to a database table. The module is organized in the standard...
1
by: fo | last post by:
Hi, I want create a page bit like an personality test or take input from users then display results based on the input and criteria required from the mysql database . For example; If you are...
3
by: planetthoughtful | last post by:
Hi All, I'm wondering if anyone can point me to a javascript that will prompt a user if they want to lose changes when they've edited one of several fields on a form and are now navigating away...
19
by: thisis | last post by:
Hi All, i have this.asp page: <script type="text/vbscript"> Function myFunc(val1ok, val2ok) ' do something ok myFunc = " return something ok" End Function </script>
5
by: kardon33 | last post by:
Im getting these errors when i use a module, could anyone tell me what they think wrong, its the second one that i think it the problem but i don't know what it means so i cant fix it, Thank you. ...
20
by: kwartz | last post by:
Any suggestions on how to write a test script to test a package. Some of the functions in the package are to_number_zero, CheckIfNumeric(STRING_IN IN VARCHAR2). I need to write some sort of test...
1
by: NIECEY | last post by:
I Would Like To Find Out How To Call A Function That Uses A For Loop And An Array To Total The Nuber Of (a)answer, (b)answer,(c)answer And (d) Answer And Then Display The Totals In Four Test Boxes.
2
by: edrichard | last post by:
Hi, I have a file that contains the following... hostMode=Standard displayName=CL1-A-0 nickname=1A-G00 hostMode=Windows Extension ...
2
by: Woodwards | last post by:
Hi, I'm new to PHP scripting. I would like to add a script to the webpage that tests the visitors browser for ACTIVE X support and pops up a message saying ACTIVE X is or is not supported by your...
6
by: tvnaidu | last post by:
Hi: Any stress test html script to test web page contains few radio buttons and apply. I have web page contains 8 radio buttons, just select on / off using radio button, then at the bottom, click on...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.