My brake lights won't flash when I drive?

Okay so I got pulled over and given a fix it ticket for my brake lights. I drive a 1995 Ford tauros. All my light work fine. When I turn on my head lights my brake lights come on to but they just won't flash when I'd I step on my break pedal. Thinking about replacing the light bulb but not sure since they do come on when I turn on my head lights at night so they work?

It could be the bulbs, but not likely that both sides would simultaneously burn out. It could be the brake light switch which is under the brake pedal. Pull the bulbs and look at them, you can tell if the filament is burned through, it will have a gap in it and be very easy to see. The brake light switch is under the dash at the top of the pedal arm, usually not hard to change. It it isn't either of those things it will be in the wiring harness, also not likely because both sides would have to fail at the same time. Probably the switch, but check the bulbs first.

*brake

Switch or fuses, VERY rare for both bulbs to blow.

I've seen plenty of times a person either has the wrong bulbs or a body shop messed up the wiring and the brake lights come on with the headlights. Then when the brake pedal is pushed the running lights come on but you don't see them because the brighter brake light element is already on. If you see dim lights working with the brake pedal while the headlights are off that's the problem.