If there is no image it returns No Rx on File, this works fine. If there is an image it returns Rx Requires Validation in a blue link. When an image is uploaded it's a 0, when it's selected as active it becomes a 1 as the active field in the database. I'm not sure how to have all images as 0 blue and now the active images that are 1 green. I thought my logic is quite busted at this point.. any help would be greatly appreciated.

Help please.


PHP Code:
if ($a['rx_scanned'] === null)
    {
         echo 
"<tr><td>**No Rx on File**</td></tr>"
    }

    
elseif (
$a['rx_scanned'] = 
    {
  
$rx_image_color '#009933';
  
      echo 
"<tr><td> &nbsp;<img src='http://sqlserver/test/tim/leaflet/check-icon.gif'>&nbsp;<a href='" 
            
matry::base_to('patient/image/view', array('event_id'=>$event->id'patient_id'=>$patient->code'uniqueid'=>$a['image_id'])) 
            . 
"' style='color:$rx_image_color'>Valid Rx on File</a></td></tr>"

    }
else  (
$a['rx_scanned'] = 0)
    { 
      
$rx_image_color '#3366FF';
      echo 
"<tr><td>" cbox_return($name) . "<a href='" 
            
matry::base_to('patient/image/view', array('event_id'=>$event->id'patient_id'=>$patient->code'uniqueid'=>$a['image_id'])) 
            . 
"'>**Rx Requires Validation**</a></td></tr>"
    } 

This was my original else statement with no syntax errors:

PHP Code:
else   
    { 
      
$rx_image_color '#3366FF';
      echo 
"<tr><td>" cbox_return($name) . "<a href='" 
            
matry::base_to('patient/image/view', array('event_id'=>$event->id'patient_id'=>$patient->code'uniqueid'=>$a['image_id'])) 
            . 
"'>**Rx Requires Validation**</a></td></tr>"
    }   

echo 
"<tr><td></td></tr>"
Although it didn't ever get to the else statement and it never functioned properly.