'empstatus'=>array('select','empstatus',array(array('','Choose One'), array('Associate','Associate'),
array('Government Employee','Government Employee'),
array('Partner','Partner'),
array('Solo Practice','Solo Practice'),
array('Independent Contractor','Independent Contractor'),
array('Law Student','Law Student'),
array('Other','Other')), array('class'=>"fillin2", 'style'=>"width:200px;"),'empstatus'),
could anyone explain me the above code? it was posted for a registration form and this is the employee status...
can an array have same values? say like array('a','a')?
Moderator: General Moderators
-
indian98476
- Forum Commoner
- Posts: 78
- Joined: Tue Dec 15, 2009 3:24 am
Re: can an array have same values? say like array('a','a')?
To the first question you asked: yes, they can have any values - it's the array keys that have to be unique.
To the question you snuck in there: It's an array. It doesn't do anything by itself, but it looks like it represents a <select> form field.
To the question you snuck in there: It's an array. It doesn't do anything by itself, but it looks like it represents a <select> form field.
-
indian98476
- Forum Commoner
- Posts: 78
- Joined: Tue Dec 15, 2009 3:24 am
Re: can an array have same values? say like array('a','a')?
thnx..it sure is a select field in form....but why do they have the field name empstatus in the end after all the other arrays?
Re: can an array have same values? say like array('a','a')?
Because that's the way whoever wrote the code designed it.