\n"; // // get a colorwheel $rotor = array(0 => 'red', 1 => 'orange', 2 => 'yellow', 3 => 'green', 4 => 'blue', 5 => 'white', 6 => 'black'); $max = 6 ; // // get the variables accepted to a known state if ($state < 0 || $state > $max || $state == "") { $state = 0; } // // and do something print ""; print "\n"; $color = $rotor[$state] ; print "
  Rotor " . "state: " . $state . " 
 Color:  " . $color . "  " . "

\n"; // $state ++; // // and let it do something neat print "
\n
\n\n"; // ?>