title: PHP if statement shortcut
body: <p>I have a script that is importing data from a csv source.  Many of the fields/columns are in "code."  For example, the school field is a numeric number apposed to the actual school name.  I need to convert the code into the actual name before it imports into the db.  </p>
  
  <p>My question is, is there a quicker way to do this conversion other than using a "if" statement.  Some of the fields that need to be converted have 20+ options so i am wondering if there is another way to write the conversion instead of having 20 if statments.  Right now I have:</p>
  
  <pre><code>if($data['school'] = 0001) {$school = "school1"; } 
  if($data['school'] = 0002) {$school = "school2"; }
  if($data['school'] = 0003) {$school = "school3"; }...
  
  or i could use if else statements
  </code></pre>
  
  <p>So my question is:  Is there a quicker way either through some sort of array or loop or other type of php statement that I could speed up this process?</p>