Play animation OnTriggerEnter (C#)

I’ve never got my head around this but I play animation through a script. so it writes to the console but doesn’t play an animation.

 using UnityEngine;
 using System.Collections;
 public class DoorTrig : MonoBehaviour {

     public GameObject door;
     void OnTriggerEnter (Collider other)
       if( == "FPSController")
             door.GetComponent<Animation>().Play("DoorOpen"); //Should play the animation
             Debug.Log("Now the animation clip should play");

Heres the Solution:

Thanks to danivdwerf:

give him a follow