Jump to content

Help With Error report for form.


cry of war

Recommended Posts

Last night I was working on my form and came across a few errors that I have no idea how to fix with all of this php script running through my html.

 

Errors:

1. Select menus don't keep the value intended selected

2. Height and choose your God are haveing issues registering

3. I cant seem to get the Yes and No raideo buttons to work the way they should. They don't register that they have a value.

 

<?
$page = "reg1.1.php";
?>
<html>
<head>
<style type="text/css">
.error {color:red;}
</style>
</head>
<body bgcolor="black" text="white">
<?
function error_flag($error, $field) {
if($error[$field]) {
	print(" class=error>");
} else {
 	print(">");
}
} //end function error_flag
function print_form() {
global $error, $print_again,$fname,$mname,$lname,$cname,$email,$cemail,$pass,$cpass,$age,$sex,$month,$day,$year,$body,$eye,$haircolor,$hairs,$length,$race,$element,$attribute,$path,$god,$skill,$skill2,$skill3,$skill4,$yes1,$no1,$yes2,$no2,$yes3,$no3,$page;
?>
<form action="<? echo $page ?>" method="post"> 
<?
if($print_again) {
	?><h3>You missed some fields. Please correct the <span class=error>red</span> fields.<?
} else {
	?><h3>Please fill-in the following fields.</h3><?
}
?>
<script language="javascript" type="text/javascript" src="ext1.js"> 	
</script>
<h3>PERSONAL INFORMATION</h3><hr>(Note that personal information is not shown on the game and all thing in this form should not be taken offensivly the only reason that these questions are filled out is because they effect the starting outcome of your character in an attempt to make each caracter different in its own way)
All of the following information may be changed by you self but it will cause you character to reset. Also you will only be given 1 chance to change any information given. Besides email or if you talk to Admin.</h8>
<hr>The odds of someone haveing the same starting stats as you are 1:51,049,164,332,808,118,084,608 plus or minus, the fact of, how common the selection of that trait is.
<hr><b><span<? error_flag($error, "fname"); ?>First Name:</span></b><INPUT TYPE="tEXT" NAME="fname"  value="<?=$fname ?>" size="20" maxlength="20"> 
<br><b><span<? error_flag($error, "mname"); ?>Middle Name:</span></b><INPUT TYPE="tEXT" NAME="mname"  value="<?=$mname ?>" size="20" maxlength="20"> 
<br><b><span<? error_flag($error, "lname"); ?>Last Name:</span></b><INPUT TYPE="tEXT" NAME="lname"  value="<?=$lname ?>" size="20" maxlength="20"> 
<br><b><span<? error_flag($error, "cname"); ?>Name of Character:</span></b><INPUT TYPE="tEXT" NAME="cname"  value="<?=$cname ?>" size="15" maxlength="15"> 
<br><b><span<? error_flag($error, "email"); ?>Email:</span></b><INPUT TYPE="tEXT" NAME="email"  value="<?=$email ?>" size="30" maxlength="30"> 
<br><b><span<? error_flag($error, "cemail"); ?>Confirm Email:</span></b><INPUT TYPE="tEXT" NAME="cemail"  value="<?=$cemail ?>" size="30" maxlength="30"> 
<br><b><span<? error_flag($error, "pass"); ?>Password:</span></b><INPUT TYPE="password" NAME="pass"  value="<?=$pass ?>" size="20" maxlength="20"> 
<br><b><span<? error_flag($error, "cpass"); ?>Confirm Password:</span></b><INPUT TYPE="password"  value="<?=$cpass ?>"  NAME="cpass" size="20" maxlength="20"> 
<br><b><span<? error_flag($error, "age"); ?>Age:</span></b><INPUT TYPE="tEXT" NAME="age"  value="<?=$age ?>" size="2" maxlength="2"> 





<br><b><span<? error_flag($error, "sex"); ?>Sex:</span></b><span id="1sex"> </span><br><div id="2sex"> </div>
<select onchange="show_txt12a(this.value); show_txt12b(this.value);" name="sex"  value="<?=$sex?>"> 
<option value=""> 
<option value="male"> Male
<option value="female"> Female
<option value="other"> Other
</select>




<hr>
<b>Birth Day</span></b><br>




<b><span<? error_flag($error, "month"); ?>Month:</span></b><span id="1month"> </span><br><div id="2month"> </div>
<select onchange="show_txt1a(this.value); show_txt1b(this.value);" name="month"  value="<?=$month ?>"> 
<option value=""> 
<option value="January"> January
<option value="February"> February
<option value="March"> March
<option value="April"> April
<option value="May"> May
<option value="June"> June
<option value="July"> July
<option value="August"> August
<option value="September"> September
<option value="October"> October
<option value="November"> November
<option value="December"> December
</select>





<br><b><span<? error_flag($error, "day"); ?>Day:</span></b>
<select name="day"  value="<?=$day ?>"> 
<option value=""> 
<option value="1"> 1
<option value="2"> 2
<option value="3"> 3
<option value="4"> 4
<option value="5"> 5
<option value="6"> 6
<option value="7"> 7
<option value="8"> 8
<option value="9"> 9
<option value="10"> 10
<option value="11"> 11
<option value="12"> 12
<option value="13"> 13
<option value="14"> 14
<option value="15"> 15
<option value="16"> 16
<option value="17"> 17
<option value="18"> 18
<option value="19"> 19
<option value="20"> 20
<option value="21"> 21
<option value="22"> 22
<option value="23"> 23
<option value="24"> 24
<option value="25"> 25
<option value="26"> 26
<option value="27"> 27
<option value="28"> 28
<option value="29"> 29
<option value="30"> 30
<option value="31"> 31
</select>




<br><b><span<? error_flag($error, "year"); ?>Year(yy):</span></b><INPUT TYPE="tEXT" NAME="year" size="2" maxlength="2"  value="<?=$year ?>"> 
<hr>




<br><b><span<? error_flag($error, "height"); ?>Height (in inches):</span></b><INPUT TYPE="text" NAME="height"  value="<?=$height ?>">



<br><b><span<? error_flag($error, "body"); ?>Body type:</span></b><span id="1body"> </span><br><div id="2body"> </div>
<select onchange="show_txt2b(this.value); show_txt2a(this.value);" name="body"  value="<?=$body ?>"> 
<option value=""> 
<option value="twig"> Twig
<option value="skinny"> Skinny
<option value="thin"> Thin
<option value="average"> Average
<option value="chunky"> Chunky
<option value="more to love"> More to love
<option value="muscular"> Muscular
<option value="body builder"> Body builder
<option value="other"> Other
</select>




<br><b><span<? error_flag($error, "eye"); ?>Eye color:</span></b><span id="1eye"> </span><br><div id="2eye"> </div>
<select onchange="show_txt3a(this.value); show_txt3b(this.value);" name="eye"  value="<?=$eye ?>"> 
<option value=""> 
<option value="black"> Black
<option value="darkbrown"> Dark Brown 
<option value="mediumbrown"> Medium brown 
<option value="lightbrown"> Light brown 
<option value="browngreenhazel"> Brown-green hazel 
<option value="darkgreen"> Dark green
<option value="green"> Green 
<option value="emeraldgreen"> Emerald green 
<option value="bluegreenhazel"> Blue-green hazel 
<option value="navyblue"> Navy blue 
<option value="mediumblue"> Medium blue 
<option value="lightblue"> Light blue  
<option value="violet"> Violet  
<option value="bluegrey"> Blue-grey
<option value="teal"> Teal
<option value="silvergray"> Silver/Gray
<option value="other"> Other 
</select>



<br><b><span<? error_flag($error, "haircolor"); ?>Hair Color:</span></b><span id="1haircolor"> </span><br><div id="2haircolor"> </div>

<select onchange="show_txt4a(this.value); show_txt4b(this.value);" name="haircolor"  value="<?=$haircolor ?>"> 
<option value=""> 
<option value="black"> Black 
<option value="sgh"> Silver/Gray
<option value="darkbrown"> Dark Brown 
<option value="mediumbrown"> Medium Brown 
<option value="lightbrown"> Light Brown 
<option value="darkauburn"> Dark Auburn 
<option value="mediumauburn"> Medium Auburn 
<option value="lightauburn"> Light Auburn 
<option value="darkred"> Dark Red 
<option value="mediumred"> Medium Red 
<option value="lightred"> Light Red 
<option value="darkstrawberryblonde"> Dark Strawberry blonde 
<option value="mediumstrawberryblonde"> Medium strawberry blonde 
<option value="lightstrawberryblonde"> Light strawberry blonde 
<option value="darkblonde"> Dark blonde 
<option value="mediumblonde"> Medium Blonde 
<option value="lightblonde"> Light Blonde 
<option value="whiteblonde"> White Blonde
<option value="otherh"> Other
</select>








<br><b><span<? error_flag($error, "hairs"); ?>Hair Style:</span></b><span id="1hairs"> </span><br><div id="2hairs"> </div>
<select onchange="show_txt5a(this.value); show_txt5b(this.value);" name="hairs"  value="<?=$hairs ?>"> 
<option value=""> 
<option value="tightcurls"> Tight curls 
<option value="mediumcurls"> Medium curls 
<option value="softcurls"> Soft curls 
<option value="verywavyhair"> Very wavy hair 
<option value="mildlyWavyhair"> Mildly Wavy hair 
<option value="wavyishhair"> Wavyish hair 
<option value="straighthair"> Straight hair
<option value="other"> Other
</select>








<br><b><span<? error_flag($error, "length"); ?>Hair length:</span></b><span id="1length"> </span><br><div id="2length"> </div>
<select onchange="show_txt6a(this.value); show_txt6b(this.value);" name="length"  value="<?=$length ?>"> 
<option value=""> 
<option value="short"> Short (bald to 1 inch)
<option value="average"> Average length (1 inch to 5 inchs)
<option value="long"> Long (5 inches and up)
</select>







<hr>
<br><h3>Character Information</h3>
<hr>







<br><b><span<? error_flag($error, "race"); ?>Choose your Characters race:</span></b><span id="1race"> </span><br><div id="2race"> </div>
<select onchange="show_txt7a(this.value); show_txt7b(this.value);" name="race"  value="<?=$race ?>"> 
<option value=""> 
<option value="elf"> Elf
<option value="human"> Human
<option value="orc"> Orc
<option value="oger"> Oger
<option value="vampire"> Vampire
<option value="werewolf"> Werewolf
<option value="darkelf"> Dark Elf
<option value="argonian"> Argonian
<option value="breton"> Breton
<option value="highelf"> High Elf
<option value="khajiit"> Khajiit
<option value="nord"> Nord
<option value="woodelf"> Wood Elf
</select>







<br><b><span<? error_flag($error, "element"); ?>Element type:</span></b><span id="1element"> </span><br><div id="2element"> </div>
<select onchange="show_txt8a(this.value); show_txt8b(this.value);" name="element"  value="<?=$element ?>"> 
<option value=""> 
<option value="fire"> Fire
<option value="water"> Water
<option value="air"> Air
<option value="earth"> Earth
</select>








<br><b><span<? error_flag($error, "attribute"); ?>Pick your characters best attribute:</span></b><span id="1attribute"> </span><br><div id="2attribute"> </div>	
<select onchange="show_txt9a(this.value); show_txt9b(this.value);" name="attribute"  value="<?=$attribute ?>"> 
<option value=""> 
<option value="strength"> Strength
<option value="endurance"> Endurance
<option value="luck"> Luck
<option value="speed"> Speed
<option value="intelligence"> Intelligence
<option value="agility"> Agility
<option value="willpower"> Willpower
<option value="endurance"> Endurance
<option value="personality"> Personality
</select>






<br><b><span<? error_flag($error, "path"); ?>Pick the Path you wish to follow:</span></b><span id="1path"> </span><br><div id="2path"> </div>
<select onchange="show_txt13a(this.value); show_txt13b(this.value);" name="path"  value="<?=$path ?>"> <br>
<option value=""> 
<option value="Death"> Death
<option value="Choas"> Choas
<option value="Life"> Life
<option value="Order"> Order
</select>








<br><span<? error_flag($error, "god"); ?><b>Choose the God you wish to worship:</b></span>
<select onchange="show_Godname(this.value); name="god"  value="<?=$god ?>"> 
<option value="">
<option value="Aerno"> Aerno
<option value="Aisilen"> Aisilen
<option value="Alenum"> Alenum
<option value="Alympol"> Alympol
<option value="Amonema"> Amonema
<option value="Anianor"> Anianor
<option value="Apymulyli"> Apymulyli
<option value="Arnomiae"> Arnomiae
<option value="Arth"> Arth
<option value="Arusoi"> Arusoi
<option value="Asmpys"> Asmpys
<option value="Atimiustus"> Atimiustus
<option value="Bicysissily"> Bicysissily
<option value="Bioesionte"> Bioesionte
<option value="Biolusstali"> Biolusstali
<option value="Bipia"> Bipia
<option value="Both"> Both
<option value="Brtathar"> Brtathar
<option value="Brth"> Brth
<option value="Caidamp"> Caidamp
<option value="Casseular"> Casseular
<option value="Centes"> Centes
<option value="Chax"> Chax
<option value="Chegocideas"> Chegocideas
<option value="Chictaralil"> Chictaralil
<option value="Chussal"> Chussal
<option value="Clicoxylc"> Clicoxylc
<option value="Crotelv"> Crotelv
<option value="Crped"> Crped
<option value="Cyst"> Cyst
<option value="Daert"> Daert
<option value="Deoetaum"> Deoetaum
<option value="Dersysides"> Dersysides
<option value="Dery"> Dery
<option value="Didarera"> Didarera
<option value="Dileniss"> Dileniss
<option value="Dipegam"> Dipegam
<option value="Disame"> Disame
<option value="Docymes"> Docymes
<option value="Doleus"> Doleus
<option value="Dond"> Dond
<option value="Donusar"> Donusar
<option value="Doria"> Doria
<option value="Elystise"> Elystise
<option value="Emeust"> Emeust
<option value="Emus"> Emus
<option value="Erabesa"> Erabesa
<option value="Eriaelional"> Eriaelional
<option value="Esaxe"> Esaxe
<option value="Eselusus"> Eselusus
<option value="Etaeo"> Etaeo
<option value="Etenitarora"> Etenitarora
<option value="Faeusi"> Faeusi
<option value="Fagar"> Fagar
<option value="Fagousacn"> Fagousacn
<option value="Famepo"> Famepo
<option value="Fareoth"> Fareoth
<option value="Fari"> Fari
<option value="Faromusm"> Faromusm
<option value="Fasiceoraeu"> Fasiceoraeu
<option value="Gabrepeagri"> Gabrepeagri
<option value="Gadisalis"> Gadisalis
<option value="Gaelioni"> Gaelioni
<option value="Gaeu"> Gaeu
<option value="Gaianane"> Gaianane
<option value="Gameuscr"> Gameuscr
<option value="Ganalal"> Ganalal
<option value="Gare"> Gare
<option value="Garem"> Garem
<option value="Garolusthe"> Garolusthe
<option value="Gdaeusias"> Gdaeusias
<option value="Gdiary"> Gdiary
<option value="Gdicr"> Gdicr
<option value="Gegalc"> Gegalc
<option value="Geiarpor"> Geiarpor
<option value="Gerus"> Gerus
<option value="Greon"> Greon
<option value="Grgo"> Grgo
<option value="Grus"> Grus
<option value="Heisi"> Heisi
<option value="Hepe"> Hepe
<option value="Herele"> Herele
<option value="Hero"> Hero
<option value="Hersony"> Hersony
<option value="Heuseiam"> Heuseiam
<option value="Hoegdisi"> Hoegdisi
<option value="Holale"> Holale
<option value="Hriart"> Hriart
<option value="Iabrt"> Iabrt
<option value="Iaeamopeu"> Iaeamopeu
<option value="Ialytheo"> Ialytheo
<option value="Ianert"> Ianert
<option value="Iaxeu"> Iaxeu
<option value="Icartab"> Icartab
<option value="Iceorpo"> Iceorpo
<option value="Idis"> Idis
<option value="Idius"> Idius
<option value="Idoche"> Idoche
<option value="Ilum"> Ilum
<option value="Imer"> Imer
<option value="Imor"> Imor
<option value="Ioro"> Ioro
<option value="Ipoda"> Ipoda
<option value="Istido"> Istido
<option value="Istostal"> Istostal
<option value="Ithym"> Ithym
<option value="Iusich"> Iusich
<option value="Iust"> Iust
<option value="Jochas"> Jochas
<option value="Jodarolisu"> Jodarolisu
<option value="Joeile"> Joeile
<option value="Joius"> Joius
<option value="Jolaluthe"> Jolaluthe
<option value="Jolerusthim"> Jolerusthim
<option value="Jolusthesag"> Jolusthesag
<option value="Jonodusisis"> Jonodusisis
<option value="Jonoith"> Jonoith
<option value="Krerstana"> Krerstana
<option value="Kreusmi"> Kreusmi
<option value="Kriaeo"> Kriaeo
<option value="Kriale"> Kriale
<option value="Krica"> Krica
<option value="Kripionche"> Kripionche
<option value="Krisaiusus"> Krisaiusus
<option value="Krit"> Krit
<option value="Krolen"> Krolen
<option value="Kror"> Kror
<option value="Krorenopp"> Krorenopp
<option value="Krpeteuseri"> Krpeteuseri
<option value="Krph"> Krph
<option value="Kryt"> Kryt
<option value="Leal"> Leal
<option value="Leoiaidolc"> Leoiaidolc
<option value="Leschi"> Leschi
<option value="Leseumonthi"> Leseumonthi
<option value="Leth"> Leth
<option value="Leuse"> Leuse
<option value="Lisiae"> Lisiae
<option value="Litad"> Litad
<option value="Liulic"> Liulic
<option value="Loilec"> Loilec
<option value="Lusalym"> Lusalym
<option value="Lviad"> Lviad
<option value="Lytasmonu"> Lytasmonu
<option value="Mabe"> Mabe
<option value="Maelipa"> Maelipa
<option value="Maeuseol"> Maeuseol
<option value="Mamisith"> Mamisith
<option value="Meaet"> Meaet
<option value="Meurega"> Meurega
<option value="Miarmusesta"> Miarmusesta
<option value="Molisop"> Molisop
<option value="Monelar"> Monelar
<option value="Mori"> Mori
<option value="Mpart"> Mpart
<option value="Muscth"> Muscth
<option value="Musiuso"> Musiuso
<option value="Mustheth"> Mustheth
<option value="Ncon"> Ncon
<option value="Negoxe"> Negoxe
<option value="Nenocthysi"> Nenocthysi
<option value="Nthe"> Nthe
<option value="Ntholeas"> Ntholeas
<option value="Nusus"> Nusus
<option value="Oleice"> Oleice
<option value="Olus"> Olus
<option value="Omacisamus"> Omacisamus
<option value="Oneryprope"> Oneryprope
<option value="Onteda"> Onteda
<option value="Onusmae"> Onusmae
<option value="Oreusum"> Oreusum
<option value="Orophiabr"> Orophiabr
<option value="Pegdilcyn"> Pegdilcyn
<option value="Pegon"> Pegon
<option value="Pheonte"> Pheonte
<option value="Phete"> Phete
<option value="Pheu"> Pheu
<option value="Phorpe"> Phorpe
<option value="Phylusesius"> Phylusesius
<option value="Potusmu"> Potusmu
<option value="Poxylal"> Poxylal
<option value="Pranus"> Pranus
<option value="Prtecyil"> Prtecyil
<option value="Pusm"> Pusm
<option value="Puth"> Puth
<option value="Pysi"> Pysi
<option value="Rarth"> Rarth
<option value="Rasteu"> Rasteu
<option value="Reaisia"> Reaisia
<option value="Rerem"> Rerem
<option value="Rererom"> Rererom
<option value="Resthiasolv"> Resthiasolv
<option value="Ricisumem"> Ricisumem
<option value="Ridoprmetho"> Ridoprmetho
<option value="Rilu"> Rilu
<option value="Rima"> Rima
<option value="Rimntenu"> Rimntenu
<option value="Risaid"> Risaid
<option value="Roleston"> Roleston
<option value="Ropemorpia"> Ropemorpia
<option value="Roresid"> Roresid
<option value="Rscephia"> Rscephia
<option value="Rtai"> Rtai
<option value="Rtatarer"> Rtatarer
<option value="Rthemoi"> Rthemoi
<option value="Rtionesusus"> Rtionesusus
<option value="Sago"> Sago
<option value="Samphoeo"> Samphoeo
<option value="Sanusu"> Sanusu
<option value="Senus"> Senus
<option value="Sicop"> Sicop
<option value="Sioneome"> Sioneome
<option value="Sioususype"> Sioususype
<option value="Sonar"> Sonar
<option value="Soriaecilia"> Soriaecilia
<option value="Staca"> Staca
<option value="Stegront"> Stegront
<option value="Stiarysa"> Stiarysa
<option value="Sybrstast"> Sybrstast
<option value="Symisial"> Symisial
<option value="Syrertesius"> Syrertesius
<option value="Tanealea"> Tanealea
<option value="Tarochesi"> Tarochesi
<option value="Tartheoc"> Tartheoc
<option value="Teiagri"> Teiagri
<option value="Temarolul"> Temarolul
<option value="Tesaeian"> Tesaeian
<option value="Theleuse"> Theleuse
<option value="Theno"> Theno
<option value="Theuss"> Theuss
<option value="Theuster"> Theuster
<option value="Thiste"> Thiste
<option value="Ullisi"> Ullisi
<option value="Ulosa"> Ulosa
<option value="Umallio"> Umallio
<option value="Umusi"> Umusi
<option value="Unumonon"> Unumonon
<option value="Usalamae"> Usalamae
<option value="Usallertero"> Usallertero
<option value="Ustepausau"> Ustepausau
<option value="Usthamenen"> Usthamenen
<option value="Usto"> Usto
<option value="Ususisi"> Ususisi
<option value="Usymio"> Usymio
<option value="Usyrto"> Usyrto
<option value="Viathrylcna"> Viathrylcna
<option value="Vichery"> Vichery
<option value="Viditho"> Viditho
<option value="Vilar"> Vilar
<option value="Vill"> Vill
<option value="Viocrntes"> Viocrntes
<option value="Vioteusicyl"> Vioteusicyl
<option value="Vipeste"> Vipeste
<option value="Viphta"> Viphta
<option value="Visanteodo"> Visanteodo
<option value="Vitesm"> Vitesm
<option value="Vitheopim"> Vitheopim
<option value="Vithoceim"> Vithoceim
<option value="Vitutus"> Vitutus
<option value="Viusth"> Viusth
<option value="Xeal"> Xeal
<option value="Xeiscegd"> Xeiscegd
<option value="Xeonac"> Xeonac
<option value="Xeonalitu"> Xeonalitu
<option value="Xerel"> Xerel
<option value="Xeriare"> Xeriare
<option value="Xernico"> Xernico
<option value="Xerymeic"> Xerymeic
<option value="Xesi"> Xesi
<option value="Xesicama"> Xesicama
<option value="Xesith"> Xesith
<option value="Xeusth"> Xeusth
<option value="Xylaliormu"> Xylaliormu
<option value="Xyphax"> Xyphax
<option value="Xyser"> Xyser
<option value="Xytausopa"> Xytausopa
<option value="Xythesthime"> Xythesthime
<option value="Xythopageus"> Xythopageus
<option value="Ybelisser"> Ybelisser
<option value="Ybobr"> Ybobr
<option value="Yisobryti"> Yisobryti
<option value="Ymegoth"> Ymegoth
<option value="Ynemisorasm"> Ynemisorasm
<option value="Ypeon"> Ypeon
<option value="Yrocyc"> Yrocyc
<option value="Ysar"> Ysar
<option value="Zeceus"> Zeceus
<option value="Zela"> Zela
<option value="Zenaury"> Zenaury
<option value="Zenegacrson"> Zenegacrson
<option value="Zeraran"> Zeraran
<option value="Zerice"> Zerice
<option value="Zesiliponus"> Zesiliponus
<option value="Zesiolesch"> Zesiolesch
<option value="Zestalenaic"> Zestalenaic
<option value="Zeulust"> Zeulust
<option value="Zeurambota"> Zeurambota
<option value="Zeuron"> Zeuron
<option value="Zeussteusas"> Zeussteusas
<option value="Zeusth"> Zeusth
</select>
<div id="description"> </div>






<hr>
<b>Stats:</b><span id="1skill"> </span><br><div id="2skill"> </div>
<br>(All other stats shown will start at level 0 untill you level up. You will be able to level your stats that you choose below as if they started at level 1. Example it takes x amount of point to get from 0 to level 1 it also takes that amount to get from level 25 to 26 if you chose that skill for a major skill. Also You can pick the same stat for each of you majoir and minor skills and you would start of with atleast a level 55 character in that stat.)<br>
<hr>







<br><b><span<? error_flag($error, "skill"); ?>Pick a main stat</span></b> (start off at level 25).
<br><select onchange="show_txt11a(this.value); show_txt11b(this.value);" name="skill"  value="<?=$skill ?>"> 
<option value=""> 
<option value="assassin1"> Assassin
<option value="warrior1"> Warrior
<option value="mage1"> Mage/Elementilist
<option value="thief1"> Thief
<option value="archer1"> Archer
<option value="smith1"> Black Smith
<option value="merchant1"> Merchant
<option value="bard1"> Bards
<option value="doctor1"> Doctor
<option value="alchemists1"> Alchemists
<option value="farmer1"> Farmer
<option value="banker1"> Banker
<option value="bartender1"> Bartender
<option value="masonary1"> Masonary
<option value="tailor1"> Tailor
<option value="cook1"> Cook
<option value="crafter1"> Crafter
<option value="jailer1"> Jailer
<option value="miner1"> Miner
<option value="guard1"> Guard
<option value="fisher1"> Fisher
<option value="rouge1"> Rouge
<option value="herder1"> Herder
</select>







<br><b><span<? error_flag($error, "skill234"); ?>Pick three stats down below for you minor stats</span></b>(start off at level 10 on each).
<br><select name="skill2"  value="<?=$skill2 ?>"> 
<option value=""> 
<option value="assassin2"> Assassin
<option value="warrior2"> Warrior
<option value="mage2"> Mage/Elementilist
<option value="thief2"> Thief
<option value="archer2"> Archer
<option value="smith2"> Black Smith
<option value="merchant2"> Merchant
<option value="bard2"> Bards
<option value="doctor2"> Doctor
<option value="alchemists2"> Alchemists
<option value="farmer2"> Farmer
<option value="banker2"> Banker
<option value="bartender2"> Bartender
<option value="masonary2"> Masonary
<option value="tailor2"> Tailor
<option value="cook2"> Cook
<option value="crafter2"> Crafter
<option value="jailer2"> Jailer
<option value="miner2"> Miner
<option value="guard2"> Guard
<option value="fisher2"> Fisher
<option value="rouge2"> Rouge
<option value="herder2"> Herder
</select>
<br><select name="skill3"  value="<?=$skill3 ?>"> 
<option value=""> 
<option value="assassin3"> Assassin
<option value="warrior3"> Warrior
<option value="mage3"> Mage/Elementilist
<option value="thief3"> Thief
<option value="archer3"> Archer
<option value="smith3"> Black Smith
<option value="merchant3"> Merchant
<option value="bard3"> Bards
<option value="doctor3"> Doctor
<option value="alchemists3"> Alchemists
<option value="farmer3"> Farmer
<option value="banker3"> Banker
<option value="bartender3"> Bartender
<option value="masonary3"> Masonary
<option value="tailor3"> Tailor
<option value="cook3"> Cook
<option value="crafter3"> Crafter
<option value="jailer3"> Jailer
<option value="miner3"> Miner
<option value="guard3"> Guard
<option value="fisher3"> Fisher
<option value="rouge3"> Rouge
<option value="herder3"> Herder
</select>
<br><select name="skill4"  value="<?=$skill4 ?>"> 
<option value=""> 
<option value="assassin4"> Assassin
<option value="warrior4"> Warrior
<option value="mage4"> Mage/Elementilist
<option value="thief4"> Thief
<option value="archer4"> Archer
<option value="smith4"> Black Smith
<option value="merchant4"> Merchant
<option value="bard4"> Bards
<option value="doctor4"> Doctor
<option value="alchemists4"> Alchemists
<option value="farmer4"> Farmer
<option value="banker4"> Banker
<option value="bartender4"> Bartender
<option value="masonary4"> Masonary
<option value="tailor4"> Tailor
<option value="cook4"> Cook
<option value="crafter4"> Crafter
<option value="jailer4"> Jailer
<option value="miner4"> Miner
<option value="guard4"> Guard
<option value="fisher4"> Fisher
<option value="rouge4"> Rouge
<option value="herder4"> Herder
</select>





<hr>
<b>Technicalities</b>
<hr>





<span<? error_flag($error, "no1"); ?>Have you read and under stand the <a href="/termsofservices.php"> Terms of services</a>, and here by agree to it?</span><br>
<input type="radio" name="term"  value="<?=$yes1 ?>"> Yes
<input type="radio" name="term"  value="<?=$no1 ?>"> No<br>
<span<? error_flag($error, "no2"); ?>Have you read and under stand the <a href="/Rules.php"> Rules of the game</a>, and here by agree to it?</span><br>
<input type="radio" name="rule"  value="<?=$yes2 ?>"> Yes
<input type="radio" name="rule"  value="<?=$no2 ?>"> No<br>
<span<? error_flag($error, "no3"); ?>Any violation to the Rules will result in your account being deleted, your Gateway IP being blocked and any or all things bought will be lost and no refunds will be granted. Do you Understand this?</span><br>
<input type="radio" name="under"  value="<?=$yes3 ?>"> Yes
<input type="radio" name="under"  value="<?=$no3 ?>"> No
<hr>
<input type="submit" name="submit"  value="Finished">  <input type="reset" name="reset"  value="Reset Form"> 
</form>
<?
} // end function print_form

function check_form() {
global $error, $print_again,$fname,$mname,$lname,$cname,$email,$cemail,$pass,$cpass,$age,$sex,$month,$day,$year,$body,$eye,$haircolor,$hairs,$length,$race,$element,$attribute,$path,$god,$skill,$skill2,$skill3,$skill4,$yes1,$no1,$yes2,$no2,$yes3,$no3;
	$error['fname'] = false;
	$error['mname'] = false;
	$error['lname'] = false;
	$error['cname'] = false;
	$error['email'] = false;
	$error['cemail'] = false;
	$error['pass'] = false;
	$error['cpass'] = false;
	$error['age'] = false;
	$error['sex'] = false;
	$error['month'] = false;
	$error['day'] = false;
	$error['year'] = false;
	$error['height'] = false;
	$error['body'] = false;
	$error['eye'] = false;
	$error['haircolor'] = false;
	$error['hairs'] = false;
	$error['length'] = false;
	$error['race'] = false;
	$error['element'] = false;
	$error['attribute'] = false;
	$error['path'] = false;
	$error['god'] = false;
	$error['skill'] = false;
	$error['skill2'] = false;
	$error['skill3'] = false;
	$error['skill4'] = false;
	$error['yes1'] = false;
	$error['no1'] = false;
	$error['yes2'] = false;
	$error['no2'] = false;
	$error['yes3'] = false;
	$error['no3'] = false;
$print_again = false;
if($fname == "") {
$error['fname'] = true;
	$print_again = true;
}	
if($mname == "") {
$error['mname'] = true;
	$print_again = true;
}	
if($lname == "") {
$error['lname'] = true;
	$print_again = true;
}	
if($cname == "") {
$error['cname'] = true;
	$print_again = true;
}	
if($email == "") {
$error['email'] = true;
	$print_again = true;
}	
if($cemail == "") {
$error['cemail'] = true;
	$print_again = true;
}	
if($pass == "") {
$error['pass'] = true;
	$print_again = true;
}	
if($cpass == "") {
$error['cpass'] = true;
	$print_again = true;
}	
if($age == "") {
$error['age'] = true;
	$print_again = true;
}	
if($sex == "") {
$error['sex'] = true;
	$print_again = true;
}	
if($month == "") {
$error['month'] = true;
	$print_again = true;
}	
if($day == "") {
$error['day'] = true;
	$print_again = true;
}	
if($year == "") {
$error['year'] = true;
	$print_again = true;
}	
if($height == "") {
$error['height'] = true;
	$print_again = true;
}
if($body == "") {
$error['body'] = true;
	$print_again = true;
}	
if($eye == "") {
$error['eye'] = true;
	$print_again = true;
}	
if($haircolor == "") {
$error['haircolor'] = true;
	$print_again = true;
}	
if($hairs == "") {
$error['hairs'] = true;
	$print_again = true;
}	
if($length == "") {
$error['length'] = true;
	$print_again = true;
}	
if($race == "") {
$error['race'] = true;
	$print_again = true;
}	
if($element == "") {
$error['element'] = true;
	$print_again = true;
}	
if($attribute == "") {
$error['attribute'] = true;
	$print_again = true;
}	
if($path == "") {
$error['path'] = true;
	$print_again = true;
}	
if($god == "") {
$error['god'] = true;
	$print_again = true;
}	
if($skill == "") {
$error['skill'] = true;
	$print_again = true;
}	
if($skill2 == "") {
$error['skill234'] = true;
	$print_again = true;
}	
if($skill3 == "") {
$error['skill234'] = true;
	$print_again = true;
}	
if($skill4 == "") {
$error['skill234'] = true;
	$print_again = true;
}	
if($term == "") {
$error['no1'] = true;
	$print_again = true;
}		
if($term == "no1") {
$error['no1'] = true;
	$print_again = true;
}		
if($rules == "") {
$error['no2'] = true;
	$print_again = true;
}	
if($rules == "no2") {
$error['no2'] = true;
	$print_again = true;
}		
if($under == "") {
$error['no3'] = true;
	$print_again = true;
}	
if($under == "no3") {
$error['no3'] = true;
	$print_again = true;
}			
if($print_again) {
	print_form();
} else {
	print("<h3>Thank you for completing the form!</h3>");
}
} // end function check_form

/***** MAIN *****/
if(isset($submit)) {
check_form();
} else {
print_form();
}
?>
</body>
</html>

Link to comment
Share on other sites

holy crap thats a massive form. i skimmed through it. i can tell you about the select boxes. the select tag in html does not actually have a value attribute. to get the right one selected you have to use:

selected="selected"

 

in the option part. so you have to test the option value against the sex and if it is right then set it as that. and all the others need to be blank...

 

i cant tell you about the others cuz it is WAY to long and i am tired.

Link to comment
Share on other sites

hmmm ok well that is only about half the form but the part that confuses me is say for a text area it has a value that is equal to its self or what ever you type into the field.

<input type="text" name="blah" value="<?=$some_rand ?>">

and the check for that would be

if($some_rand == "") {
$error['something_else'] = true;
	$print_again = true;
}	

but how to you do the same thing as above for

<select name="sex"> 
<option value=""> 
<option value="male"> Male
<option value="female"> Female
<option value="other"> Other
</select>

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.