Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

else if statements in cgi

Status
Not open for further replies.

georgeous

Programmer
Jul 11, 2001
38
0
0
GB
I have an if statement with 3 options in my cgi script.
Is the correct syntax like this

if (condition one) {
do this}

else if (condition two) {
do this}

else (condition three) {
do this}


I've got this implemented, but it keeps throwing up error messages.

am i doing something wrong?
 
Code:
if (condition one) {
 # do this
} elsif (condition two)  {
 # do this
} else (condition three) {
 # do this
}
---------------------------------------
wmail.jpg


someone knowledge ends where
someone else knowledge starts
 
its okay now, i'd forgotten to close a bracket!

silly me
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top