Minecraft wiki entry for Dispenser, associated text: an adjacent active power component: for example, a redstone torch (except that a redstone torch does not activate a dispenser it is attached to), a block of redstone, a daylight sensor, etc.
an adjacent powered opaque block (for example, a block with an active redstone torch under it)
a powered redstone repeater or redstone comparator facing the dispenser
powered redstone dust configured to point at the dispenser, or on top of it, or a directionless "cross" next to it; a dispenser is not activated by adjacent powered redstone dust that is configured to point in another direction.